Plugin Directory

Changeset 2517018


Ignore:
Timestamp:
04/18/2021 06:05:27 AM (5 years ago)
Author:
pinecast
Message:

[1.1.0] Version 1.1.0

Location:
pinecast-wp-sync
Files:
24 edited
1 copied

Legend:

Unmodified
Added
Removed
  • pinecast-wp-sync/tags/1.1.0/dist/admin/css/pinecast.min.css

    r2120413 r2517018  
    1 #pinecast-add-podcast{margin-top:10px}.pinecast-feed-template{display:none}.pinecast-feed{background:#fff}.pinecast-feed .pinecast-feed-header{display:flex;flex-grow:1;height:30px;cursor:pointer;font-size:14px;padding:12px 7px 12px 12px;line-height:30px;font-weight:600;border-bottom:1px solid #eee}.pinecast-feed .pinecast-feed-header .title{flex-grow:1}.pinecast-feed .pinecast-feed-header .title .placeholder{color:#999}.pinecast-feed .pinecast-feed-header .delete{color:#a00;line-height:20px;vertical-align:middle;font-size:13px;margin-right:1em;height:20px;margin-top:5px;margin-bottom:5px;display:inline-block;font-weight:normal;visibility:hidden}.pinecast-feed .pinecast-feed-header .delete:hover{color:#dc3232}.pinecast-feed .pinecast-feed-header .handlediv{width:36px;display:block;justify-self:flex-end;height:36px;margin:0;padding:0;border:0;background:none;cursor:pointer}.pinecast-feed .pinecast-feed-header .handlediv:before{content:"\f141";display:inline-block;font:normal 20px/1 dashicons;speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-decoration:none !important;padding:0;right:0;vertical-align:middle}.pinecast-feed .pinecast-feed-header:hover .delete{visibility:visible}.pinecast-feed .pinecast-feed-body{display:none;background:#f9f9f9;border-bottom:1px solid #eee}.pinecast-feed .pinecast-feed-body .row{display:flex;flex-direction:row;width:100%}.pinecast-feed .pinecast-feed-body .row .label{border-color:#e5e5e5;border-width:0 1px 1px 0;border-style:solid;padding:15px 10px;font-weight:bold;background:#F9F9F9;width:200px}.pinecast-feed .pinecast-feed-body .row .field{padding:15px 10px;width:100%;border-bottom:1px solid #e5e5e5;background:#fff}.pinecast-feed .pinecast-feed-body .row .field input,.pinecast-feed .pinecast-feed-body .row .field textarea,.pinecast-feed .pinecast-feed-body .row .field select{width:100%;box-sizing:border-box;font-size:14px;line-height:1.4}.pinecast-feed .pinecast-feed-body .row .field input[type='radio'],.pinecast-feed .pinecast-feed-body .row .field input[type='checkbox']{width:auto !important}.pinecast-feed .pinecast-feed-body .row:last-of-type .label,.pinecast-feed .pinecast-feed-body .row:last-of-type .field{border-bottom:none}.pinecast-feed .pinecast-feed-body .row .description{color:#788;font-size:12px;font-weight:normal}.pinecast-feed .pinecast-feed-body .row.actions{background:red !important}.pinecast-feed .pinecast-feed-body .row.actions .button .dashicons{line-height:27px;height:27px}.pinecast-feed.open .pinecast-feed-body{display:block}.pinecast-feed.open .handlediv:before{content:'\f140'}.spinner{float:none}
     1#pinecast-add-podcast{margin-top:10px}.pinecast-feed-template{display:none}.pinecast-feed{background:#fff}.pinecast-feed .pinecast-feed-header{display:flex;flex-grow:1;height:30px;cursor:pointer;font-size:14px;padding:12px 7px 12px 12px;line-height:30px;font-weight:600;border-bottom:1px solid #eee}.pinecast-feed .pinecast-feed-header .title{flex-grow:1;font-size:14px;font-weight:400;line-height:1em;margin:0}.pinecast-feed .pinecast-feed-header .title .placeholder{color:#999}.pinecast-feed .pinecast-feed-header .delete{appearance:none;background:transparent;border:0;color:#a00;display:inline-block;font-size:13px;font-weight:normal;height:20px;line-height:20px;margin-bottom:5px;margin-right:1em;margin-top:5px;vertical-align:middle;visibility:hidden}.pinecast-feed .pinecast-feed-header .delete:hover{color:#dc3232}.pinecast-feed .pinecast-feed-header .handlediv{width:36px;display:block;justify-self:flex-end;height:36px;margin:0;padding:0;border:0;background:none;cursor:pointer}.pinecast-feed .pinecast-feed-header .handlediv:before{content:"\f141";display:inline-block;font:normal 20px/1 dashicons;speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-decoration:none !important;padding:0;right:0;vertical-align:middle}.pinecast-feed .pinecast-feed-header:hover .delete{visibility:visible}.pinecast-feed .pinecast-feed-body{display:none;background:#f9f9f9;border-bottom:1px solid #eee}.pinecast-feed .pinecast-feed-body .row{display:flex;flex-direction:row;width:100%}.pinecast-feed .pinecast-feed-body .row .label{border-color:#e5e5e5;border-width:0 1px 1px 0;border-style:solid;padding:15px 10px;font-weight:bold;background:#F9F9F9;width:200px}.pinecast-feed .pinecast-feed-body .row .field{padding:15px 10px;width:100%;border-bottom:1px solid #e5e5e5;background:#fff}.pinecast-feed .pinecast-feed-body .row .field input,.pinecast-feed .pinecast-feed-body .row .field textarea,.pinecast-feed .pinecast-feed-body .row .field select{width:100%;box-sizing:border-box;font-size:14px;line-height:1.4}.pinecast-feed .pinecast-feed-body .row .field input[type='radio'],.pinecast-feed .pinecast-feed-body .row .field input[type='checkbox']{width:auto !important}.pinecast-feed .pinecast-feed-body .row:last-of-type .label,.pinecast-feed .pinecast-feed-body .row:last-of-type .field{border-bottom:none}.pinecast-feed .pinecast-feed-body .row .description{color:#788;font-size:12px;font-weight:normal}.pinecast-feed .pinecast-feed-body .row.actions{background:red !important}.pinecast-feed .pinecast-feed-body .row.actions .button .dashicons{line-height:27px;height:27px}.pinecast-feed.open .pinecast-feed-body{display:block}.pinecast-feed.open .handlediv:before{content:'\f140'}.spinner{float:none}
    22
    33/*# sourceMappingURL=pinecast.min.css.map */
  • pinecast-wp-sync/tags/1.1.0/dist/admin/css/pinecast.min.css.map

    r2120413 r2517018  
    1 {"version":3,"file":"pinecast.min.css","sources":["pinecast.scss"],"sourcesContent":["#pinecast-add-podcast {\n\tmargin-top: 10px;\n}\n\n\n.pinecast-feed-template {\n\tdisplay: none;\n}\n.pinecast-feed {\n\tbackground: #fff;\n\n\t// Header\n\t.pinecast-feed-header {\n\t\tdisplay: flex;\n\t\tflex-grow: 1;\n\t\theight: 30px;\n\t\tcursor: pointer;\n\t\tfont-size: 14px;\n\t\tpadding: 12px 7px 12px 12px;\n\t\tline-height: 30px;\n\t\tfont-weight: 600;\n\t\tborder-bottom: 1px solid #eee;\n\n\t\t.title {\n\t\t\tflex-grow: 1;\n\n\t\t\t.placeholder {\n\t\t\t\tcolor: #999;\n\t\t\t}\n\t\t}\n\t\t.delete {\n\t\t\tcolor: #a00;\n\t\t\tline-height: 20px;\n\t\t\tvertical-align: middle;\n\t\t\tfont-size: 13px;\n\t\t\tmargin-right: 1em;\n\t\t\theight: 20px;\n\t\t\tmargin-top: 5px;\n\t\t\tmargin-bottom: 5px;\n\t\t\tdisplay: inline-block;\n\t\t\tfont-weight: normal;\n\t\t\tvisibility: hidden;\n\n\t\t\t&:hover {\n\t\t\t\tcolor: #dc3232;\n\t\t\t}\n\t\t}\n\n\t\t.handlediv {\n\t\t\twidth: 36px;\n\t\t\tdisplay: block;\n\t\t\tjustify-self: flex-end;\n\t\t\theight: 36px;\n\t\t\tmargin: 0;\n\t\t\tpadding: 0;\n\t\t\tborder: 0;\n\t\t\tbackground: none;\n\t\t\tcursor: pointer;\n\n\t\t\t&:before {\n\t\t\t\tcontent: \"\\f141\";\n\t\t\t\tdisplay: inline-block;\n\t\t\t\tfont: normal 20px/1 dashicons;\n\t\t\t\tspeak: none;\n\t\t\t\t-webkit-font-smoothing: antialiased;\n\t\t\t\t-moz-osx-font-smoothing: grayscale;\n\t\t\t\ttext-decoration: none !important;\n\t\t\t\tpadding: 0;\n\t\t\t\tright: 0;\n\t\t\t\tvertical-align: middle;\n\t\t\t}\n\t\t}\n\n\t\t&:hover {\n\n\t\t\t.delete {\n\t\t\t\tvisibility: visible;\n\t\t\t}\n\t\t}\n\t}\n\t.pinecast-feed-body {\n\t\tdisplay: none;\n\n\t\tbackground: #f9f9f9;\n\t\t//padding: 12px;\n\t\tborder-bottom: 1px solid #eee;\n\n\t\t.row {\n\t\t\tdisplay: flex;\n\t\t\tflex-direction: row;\n\t\t\twidth: 100%;\n\n\t\t\t.label {\n\t\t\t\tborder-color: #e5e5e5;\n\t\t\t\tborder-width: 0 1px 1px 0;\n\t\t\t\tborder-style: solid;\n\t\t\t\tpadding: 15px 10px;\n\t\t\t\tfont-weight: bold;\n\t\t\t\tbackground: #F9F9F9;\n\t\t\t\twidth: 200px;\n\t\t\t}\n\t\t\t.field {\n\t\t\t\tpadding: 15px 10px;\n\t\t\t\twidth: 100%;\n\t\t\t\tborder-bottom: 1px solid #e5e5e5;\n\t\t\t\tbackground: #fff;\n\n\t\t\t\tinput,\n\t\t\t\ttextarea,\n\t\t\t\tselect {\n\t\t\t\t\twidth: 100%;\n\t\t\t\t\tbox-sizing: border-box;\n\t\t\t\t\tfont-size: 14px;\n\t\t\t\t\tline-height: 1.4;\n\t\t\t\t}\n\t\t\t\tinput[type='radio'],\n\t\t\t\tinput[type='checkbox'] {\n\t\t\t\t\twidth: auto !important;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&:last-of-type {\n\t\t\t\t.label, .field {\n\t\t\t\t\tborder-bottom: none;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t.description {\n\t\t\t\tcolor: #788;\n\t\t\t\tfont-size: 12px;\n\t\t\t\tfont-weight: normal;\n\t\t\t}\n\t\t}\n\n\t\t/** Element specific */\n\t\t.row.actions {\n\t\t\tbackground: red !important;\n\t\t\t.button {\n\n\t\t\t\t.dashicons {\n\t\t\t\t\tline-height: 27px;\n\t\t\t\t\theight: 27px;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t&.open {\n\n\t\t.pinecast-feed-body {\n\t\t\tdisplay: block;\n\t\t}\n\t\t.handlediv:before {\n\t\t\tcontent: '\\f140';\n\t\t}\n\t}\n}\n\n\n.spinner {\n\tfloat: none;\n}\n"],"names":[],"mappings":"AAAA,AAAA,qBAAqB,AAAC,CACrB,UAAU,CAAE,IAAI,CAChB,AAGD,AAAA,uBAAuB,AAAC,CACvB,OAAO,CAAE,IAAI,CACb,AACD,AAAA,cAAc,AAAC,CACd,UAAU,CAAE,IAAI,CAkJhB,AAnJD,AAIC,cAJa,CAIb,qBAAqB,AAAC,CACrB,OAAO,CAAE,IAAI,CACb,SAAS,CAAE,CAAC,CACZ,MAAM,C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Eb,mBAAmB,CAOlB,IAAI,CAcH,MAAM,CAcL,KAAK,CAAA,AAAA,IAAC,CAAK,OAAO,AAAZ,EA3GV,cAAc,CAwEb,mBAAmB,CAOlB,IAAI,CAcH,MAAM,CAeL,KAAK,CAAA,AAAA,IAAC,CAAK,UAAU,AAAf,CAAiB,CACtB,KAAK,CAAE,eAAe,CACtB,AA9GL,AAkHI,cAlHU,CAwEb,mBAAmB,CAOlB,IAAI,AAkCF,aAAa,CACb,MAAM,CAlHV,cAAc,CAwEb,mBAAmB,CAOlB,IAAI,AAkCF,aAAa,CACL,MAAM,AAAC,CACd,aAAa,CAAE,IAAI,CACnB,AApHL,AAuHG,cAvHW,CAwEb,mBAAmB,CAOlB,IAAI,CAwCH,YAAY,AAAC,CACZ,KAAK,CAAE,IAAI,CACX,SAAS,CAAE,IAAI,CACf,WAAW,CAAE,MAAM,CACnB,AA3HJ,AA+HE,cA/HY,CAwEb,mBAAmB,CAuDlB,IAAI,AAAA,QAAQ,AAAC,CACZ,UAAU,CAAE,cAAc,CAQ1B,AAxIH,AAmII,cAnIU,CAwEb,mBAAmB,CAuDlB,IAAI,AAAA,QAAQ,CAEX,OAAO,CAEN,UAAU,AAAC,CACV,WAAW,CAAE,IAAI,CACjB,MAAM,CAAE,IAAI,CACZ,AAtIL,AA4IE,cA5IY,AA0IZ,KAAK,CAEL,mBAAmB,AAAC,CACnB,OAAO,CAAE,KAAK,CACd,AA9IH,AA+IE,cA/IY,AA0IZ,KAAK,CAKL,UAAU,AAAA,OAAO,AAAC,CACjB,OAAO,CAAE,OAAO,CAChB,AAKH,AAAA,QAAQ,AAAC,CACR,KAAK,CAAE,IAAI,CACX"}
     1{"version":3,"file":"pinecast.min.css","sources":["pinecast.scss"],"sourcesContent":["#pinecast-add-podcast {\n\tmargin-top: 10px;\n}\n\n\n.pinecast-feed-template {\n\tdisplay: none;\n}\n.pinecast-feed {\n\tbackground: #fff;\n\n\t// Header\n\t.pinecast-feed-header {\n\t\tdisplay: flex;\n\t\tflex-grow: 1;\n\t\theight: 30px;\n\t\tcursor: pointer;\n\t\tfont-size: 14px;\n\t\tpadding: 12px 7px 12px 12px;\n\t\tline-height: 30px;\n\t\tfont-weight: 600;\n\t\tborder-bottom: 1px solid #eee;\n\n\t\t.title {\n\t\t\tflex-grow: 1;\n\t\t\tfont-size: 14px;\n\t\t\tfont-weight: 400;\n\t\t\tline-height: 1em;\n\t\t\tmargin: 0;\n\n\t\t\t.placeholder {\n\t\t\t\tcolor: #999;\n\t\t\t}\n\t\t}\n\t\t.delete {\n\t\t\tappearance: none;\n\t\t\tbackground: transparent;\n\t\t\tborder: 0;\n\t\t\tcolor: #a00;\n\t\t\tdisplay: inline-block;\n\t\t\tfont-size: 13px;\n\t\t\tfont-weight: normal;\n\t\t\theight: 20px;\n\t\t\tline-height: 20px;\n\t\t\tmargin-bottom: 5px;\n\t\t\tmargin-right: 1em;\n\t\t\tmargin-top: 5px;\n\t\t\tvertical-align: middle;\n\t\t\tvisibility: hidden;\n\n\t\t\t&:hover {\n\t\t\t\tcolor: #dc3232;\n\t\t\t}\n\t\t}\n\n\t\t.handlediv {\n\t\t\twidth: 36px;\n\t\t\tdisplay: block;\n\t\t\tjustify-self: flex-end;\n\t\t\theight: 36px;\n\t\t\tmargin: 0;\n\t\t\tpadding: 0;\n\t\t\tborder: 0;\n\t\t\tbackground: none;\n\t\t\tcursor: pointer;\n\n\t\t\t&:before {\n\t\t\t\tcontent: \"\\f141\";\n\t\t\t\tdisplay: inline-block;\n\t\t\t\tfont: normal 20px/1 dashicons;\n\t\t\t\tspeak: none;\n\t\t\t\t-webkit-font-smoothing: antialiased;\n\t\t\t\t-moz-osx-font-smoothing: grayscale;\n\t\t\t\ttext-decoration: none !important;\n\t\t\t\tpadding: 0;\n\t\t\t\tright: 0;\n\t\t\t\tvertical-align: middle;\n\t\t\t}\n\t\t}\n\n\t\t&:hover {\n\t\t\t.delete {\n\t\t\t\tvisibility: visible;\n\t\t\t}\n\t\t}\n\t}\n\t.pinecast-feed-body {\n\t\tdisplay: none;\n\n\t\tbackground: #f9f9f9;\n\t\t//padding: 12px;\n\t\tborder-bottom: 1px solid #eee;\n\n\t\t.row {\n\t\t\tdisplay: flex;\n\t\t\tflex-direction: row;\n\t\t\twidth: 100%;\n\n\t\t\t.label {\n\t\t\t\tborder-color: #e5e5e5;\n\t\t\t\tborder-width: 0 1px 1px 0;\n\t\t\t\tborder-style: solid;\n\t\t\t\tpadding: 15px 10px;\n\t\t\t\tfont-weight: bold;\n\t\t\t\tbackground: #F9F9F9;\n\t\t\t\twidth: 200px;\n\t\t\t}\n\t\t\t.field {\n\t\t\t\tpadding: 15px 10px;\n\t\t\t\twidth: 100%;\n\t\t\t\tborder-bottom: 1px solid #e5e5e5;\n\t\t\t\tbackground: #fff;\n\n\t\t\t\tinput,\n\t\t\t\ttextarea,\n\t\t\t\tselect {\n\t\t\t\t\twidth: 100%;\n\t\t\t\t\tbox-sizing: border-box;\n\t\t\t\t\tfont-size: 14px;\n\t\t\t\t\tline-height: 1.4;\n\t\t\t\t}\n\t\t\t\tinput[type='radio'],\n\t\t\t\tinput[type='checkbox'] {\n\t\t\t\t\twidth: auto !important;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&:last-of-type {\n\t\t\t\t.label, .field {\n\t\t\t\t\tborder-bottom: none;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t.description {\n\t\t\t\tcolor: #788;\n\t\t\t\tfont-size: 12px;\n\t\t\t\tfont-weight: normal;\n\t\t\t}\n\t\t}\n\n\t\t/** Element specific */\n\t\t.row.actions {\n\t\t\tbackground: red !important;\n\t\t\t.button {\n\n\t\t\t\t.dashicons {\n\t\t\t\t\tline-height: 27px;\n\t\t\t\t\theight: 27px;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t&.open {\n\n\t\t.pinecast-feed-body {\n\t\t\tdisplay: block;\n\t\t}\n\t\t.handlediv:before {\n\t\t\tcontent: '\\f140';\n\t\t}\n\t}\n}\n\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,AAAC,CACV,WAAW,CAAE,IAAI,CACjB,MAAM,CAAE,IAAI,CACZ,AA5IL,AAkJE,cAlJY,AAgJZ,KAAK,CAEL,mBAAmB,AAAC,CACnB,OAAO,CAAE,KAAK,CACd,AApJH,AAqJE,cArJY,AAgJZ,KAAK,CAKL,UAAU,AAAA,OAAO,AAAC,CACjB,OAAO,CAAE,OAAO,CAChB,AAKH,AAAA,QAAQ,AAAC,CACR,KAAK,CAAE,IAAI,CACX"}
  • pinecast-wp-sync/tags/1.1.0/includes/admin/settings.php

    r2423119 r2517018  
    6464        ?><div class="wrap">
    6565
    66 <!--            <h1>Pinecast</h1>-->
    67             <svg width="122" height="19" xmlns="http://www.w3.org/2000/svg" style="padding: 15px 0 4px 0;"><g fill="none" fill-rule="evenodd"><path d="M41.99 17h-2.48V2.8h4.96c3.08 0 5.04 1.72 5.04 4.42 0 2.74-1.94 4.46-5.04 4.46h-2.48V17zm0-7.44h2.34c1.72 0 2.7-.84 2.7-2.3s-.98-2.3-2.7-2.3h-2.34v4.6zM53.69 17h-2.4V6.6h2.4V17zm.24-13.12c0 .82-.6 1.44-1.44 1.44-.82 0-1.44-.62-1.44-1.44 0-.84.62-1.44 1.44-1.44.84 0 1.44.6 1.44 1.44zM58.55 17h-2.4V6.6h2.4v1.04c.88-.88 1.94-1.32 3.16-1.32 2.24 0 3.56 1.46 3.56 3.92V17h-2.4v-6.36c0-1.46-.66-2.24-1.9-2.24-.86 0-1.72.44-2.42 1.22V17zm18.02-4.34h-7c.24 1.72 1.16 2.62 2.68 2.62 1 0 1.98-.4 2.9-1.16l1.06 1.7a6.23 6.23 0 0 1-4.04 1.46c-3.1 0-5.04-2.08-5.04-5.42 0-3.32 1.94-5.54 4.84-5.54 2.8 0 4.6 2.1 4.6 5.42v.92zM71.93 8.2c-1.36 0-2.3 1.14-2.36 2.82h4.64c-.06-1.72-.94-2.82-2.28-2.82zm12.9 5.12l2.08 1.06c-.88 1.84-2.48 2.9-4.38 2.9-2.82 0-4.74-2.22-4.74-5.44 0-3.26 2-5.52 4.88-5.52 1.9 0 3.38.98 4.2 2.76l-2.1 1.02c-.44-1.12-1.16-1.7-2.12-1.7-1.5 0-2.46 1.34-2.46 3.4 0 2.04.94 3.4 2.36 3.4.96 0 1.76-.66 2.28-1.88zm7.8-4.96c-1.06 0-2.18.32-3.48 1l-.72-1.94c1.62-.76 3.06-1.1 4.54-1.1 2.68 0 3.96 1.18 3.96 3.64v3.62c0 1.48.14 1.98.72 2.44l-1.54 1.26c-.7-.28-1.12-.66-1.34-1.18-.9.8-1.88 1.18-3.02 1.18-2.22 0-3.7-1.36-3.7-3.4 0-2.28 1.7-3.18 6.48-3.4v-.46c0-1.14-.6-1.66-1.9-1.66zm-.18 7.08c.78 0 1.46-.28 2.08-.86v-2.5c-3.28.28-4.08.62-4.08 1.74 0 1 .78 1.62 2 1.62zm6.9-5.82c0-1.94 1.58-3.3 3.86-3.3 1.28 0 2.58.42 3.82 1.24l-1.16 1.8c-1.02-.72-1.9-1.08-2.66-1.08-.84 0-1.46.44-1.46 1.08 0 1.88 5.52.84 5.52 4.52 0 2.02-1.66 3.4-4.08 3.4-1.46 0-3-.5-4.36-1.44l1.2-1.78c1.16.84 2.22 1.26 3.2 1.26 1 0 1.64-.44 1.64-1.12 0-1.98-5.52-.96-5.52-4.58zm8.86-1.14V6.6h1.84V3.8l2.4-.48V6.6h2.8v1.88h-2.8v5.26c0 .94.42 1.38 1.3 1.38.4 0 .92-.1 1.38-.26l.36 1.84c-.92.3-1.74.46-2.46.46-1.92 0-2.98-1.06-2.98-3.02V8.48h-1.84z" fill="#3F3F3F"/><g fill="#1FD2C4"><path d="M7.03 16.09h17.818a9.84 9.84 0 0 0 .1-6.39c-.798-2.454-2.485-4.443-4.752-5.603a9.258 9.258 0 0 0-7.245-.535c-4.968 1.68-7.669 7.167-6.021 12.233.032.099.065.197.1.295m23.595 2.452H6.245c-.425 0-.818-.23-1.034-.601l-.071-.121a1.372 1.372 0 0 1-.064-.127c-.16-.367-.305-.746-.428-1.126-2.065-6.349 1.32-13.227 7.545-15.333a11.615 11.615 0 0 1 9.081.672c2.84 1.453 4.955 3.947 5.956 7.022.76 2.337.804 4.826.146 7.162h3.249c.664 0 1.202.55 1.202 1.226 0 .676-.538 1.226-1.202 1.226"/><path d="M17.141 12.893c0 .677-.538 1.225-1.202 1.225a1.214 1.214 0 0 1-1.202-1.225c0-.678.538-1.226 1.202-1.226.664 0 1.202.548 1.202 1.226"/><path d="M9.881 14.118c-.66 0-1.196-.541-1.202-1.215a7.56 7.56 0 0 1 .95-3.729 7.281 7.281 0 0 1 4.408-3.509 7.136 7.136 0 0 1 5.55.698 7.295 7.295 0 0 1 2.123 1.85c.412.53.325 1.3-.195 1.721a1.186 1.186 0 0 1-1.689-.198 4.907 4.907 0 0 0-1.424-1.24 4.792 4.792 0 0 0-3.724-.468 4.887 4.887 0 0 0-2.957 2.354 5.065 5.065 0 0 0-.638 2.5 1.215 1.215 0 0 1-1.192 1.236h-.01zM1.202 18.602C.54 18.602 0 18.052 0 17.376c0-.677.539-1.226 1.202-1.226h1.503c.663 0 1.202.55 1.202 1.226 0 .676-.539 1.226-1.202 1.226H1.202z"/></g><path d="M118.496 15.443H118V15h1.488v.443h-.496V17h-.496v-1.557zM119.97 15h.514l.294.83.103.327h.012l.104-.326.282-.831h.513v2h-.46v-.59c0-.052.002-.108.006-.17a17.151 17.151 0 0 1 .036-.378l.02-.167h-.011l-.156.468-.26.674h-.184l-.26-.674-.149-.468h-.012l.02.167a5.393 5.393 0 0 1 .037.378c.004.062.007.118.007.17V17h-.456v-2z" fill="#2C253C"/></g></svg><?php
     66      <h1 aria-label="Pinecast"><svg width="122" height="19" xmlns="http://www.w3.org/2000/svg" style="padding: 15px 0 4px 0;"><g fill="none" fill-rule="evenodd"><path d="M41.99 17h-2.48V2.8h4.96c3.08 0 5.04 1.72 5.04 4.42 0 2.74-1.94 4.46-5.04 4.46h-2.48V17zm0-7.44h2.34c1.72 0 2.7-.84 2.7-2.3s-.98-2.3-2.7-2.3h-2.34v4.6zM53.69 17h-2.4V6.6h2.4V17zm.24-13.12c0 .82-.6 1.44-1.44 1.44-.82 0-1.44-.62-1.44-1.44 0-.84.62-1.44 1.44-1.44.84 0 1.44.6 1.44 1.44zM58.55 17h-2.4V6.6h2.4v1.04c.88-.88 1.94-1.32 3.16-1.32 2.24 0 3.56 1.46 3.56 3.92V17h-2.4v-6.36c0-1.46-.66-2.24-1.9-2.24-.86 0-1.72.44-2.42 1.22V17zm18.02-4.34h-7c.24 1.72 1.16 2.62 2.68 2.62 1 0 1.98-.4 2.9-1.16l1.06 1.7a6.23 6.23 0 0 1-4.04 1.46c-3.1 0-5.04-2.08-5.04-5.42 0-3.32 1.94-5.54 4.84-5.54 2.8 0 4.6 2.1 4.6 5.42v.92zM71.93 8.2c-1.36 0-2.3 1.14-2.36 2.82h4.64c-.06-1.72-.94-2.82-2.28-2.82zm12.9 5.12l2.08 1.06c-.88 1.84-2.48 2.9-4.38 2.9-2.82 0-4.74-2.22-4.74-5.44 0-3.26 2-5.52 4.88-5.52 1.9 0 3.38.98 4.2 2.76l-2.1 1.02c-.44-1.12-1.16-1.7-2.12-1.7-1.5 0-2.46 1.34-2.46 3.4 0 2.04.94 3.4 2.36 3.4.96 0 1.76-.66 2.28-1.88zm7.8-4.96c-1.06 0-2.18.32-3.48 1l-.72-1.94c1.62-.76 3.06-1.1 4.54-1.1 2.68 0 3.96 1.18 3.96 3.64v3.62c0 1.48.14 1.98.72 2.44l-1.54 1.26c-.7-.28-1.12-.66-1.34-1.18-.9.8-1.88 1.18-3.02 1.18-2.22 0-3.7-1.36-3.7-3.4 0-2.28 1.7-3.18 6.48-3.4v-.46c0-1.14-.6-1.66-1.9-1.66zm-.18 7.08c.78 0 1.46-.28 2.08-.86v-2.5c-3.28.28-4.08.62-4.08 1.74 0 1 .78 1.62 2 1.62zm6.9-5.82c0-1.94 1.58-3.3 3.86-3.3 1.28 0 2.58.42 3.82 1.24l-1.16 1.8c-1.02-.72-1.9-1.08-2.66-1.08-.84 0-1.46.44-1.46 1.08 0 1.88 5.52.84 5.52 4.52 0 2.02-1.66 3.4-4.08 3.4-1.46 0-3-.5-4.36-1.44l1.2-1.78c1.16.84 2.22 1.26 3.2 1.26 1 0 1.64-.44 1.64-1.12 0-1.98-5.52-.96-5.52-4.58zm8.86-1.14V6.6h1.84V3.8l2.4-.48V6.6h2.8v1.88h-2.8v5.26c0 .94.42 1.38 1.3 1.38.4 0 .92-.1 1.38-.26l.36 1.84c-.92.3-1.74.46-2.46.46-1.92 0-2.98-1.06-2.98-3.02V8.48h-1.84z" fill="#3F3F3F"/><g fill="#0066ff"><path d="M7.03 16.09h17.818a9.84 9.84 0 0 0 .1-6.39c-.798-2.454-2.485-4.443-4.752-5.603a9.258 9.258 0 0 0-7.245-.535c-4.968 1.68-7.669 7.167-6.021 12.233.032.099.065.197.1.295m23.595 2.452H6.245c-.425 0-.818-.23-1.034-.601l-.071-.121a1.372 1.372 0 0 1-.064-.127c-.16-.367-.305-.746-.428-1.126-2.065-6.349 1.32-13.227 7.545-15.333a11.615 11.615 0 0 1 9.081.672c2.84 1.453 4.955 3.947 5.956 7.022.76 2.337.804 4.826.146 7.162h3.249c.664 0 1.202.55 1.202 1.226 0 .676-.538 1.226-1.202 1.226"/><path d="M17.141 12.893c0 .677-.538 1.225-1.202 1.225a1.214 1.214 0 0 1-1.202-1.225c0-.678.538-1.226 1.202-1.226.664 0 1.202.548 1.202 1.226"/><path d="M9.881 14.118c-.66 0-1.196-.541-1.202-1.215a7.56 7.56 0 0 1 .95-3.729 7.281 7.281 0 0 1 4.408-3.509 7.136 7.136 0 0 1 5.55.698 7.295 7.295 0 0 1 2.123 1.85c.412.53.325 1.3-.195 1.721a1.186 1.186 0 0 1-1.689-.198 4.907 4.907 0 0 0-1.424-1.24 4.792 4.792 0 0 0-3.724-.468 4.887 4.887 0 0 0-2.957 2.354 5.065 5.065 0 0 0-.638 2.5 1.215 1.215 0 0 1-1.192 1.236h-.01zM1.202 18.602C.54 18.602 0 18.052 0 17.376c0-.677.539-1.226 1.202-1.226h1.503c.663 0 1.202.55 1.202 1.226 0 .676-.539 1.226-1.202 1.226H1.202z"/></g><path d="M118.496 15.443H118V15h1.488v.443h-.496V17h-.496v-1.557zM119.97 15h.514l.294.83.103.327h.012l.104-.326.282-.831h.513v2h-.46v-.59c0-.052.002-.108.006-.17a17.151 17.151 0 0 1 .036-.378l.02-.167h-.011l-.156.468-.26.674h-.184l-.26-.674-.149-.468h-.012l.02.167a5.393 5.393 0 0 1 .037.378c.004.062.007.118.007.17V17h-.456v-2z" fill="#2C253C"/></g></svg></h1>
     67            <?php
    6868            settings_errors( "pinecast_settings_page" );
    6969
     
    9292
    9393        if ( empty( $podcasts ) ) {
    94             $podcasts = array(
     94            $podcasts = array(
    9595                Podcast::create( mt_rand( 10000000, 99999999 ), array() )
    96             );
    97         }
     96            );
     97        }
    9898
    9999        ?><div class="pinecast-feeds-wrap">
    100             <div class="pinecast-feeds"><?php
    101                 foreach ( $podcasts as $k => $podcast ) :
    102                    require 'views/podcast-row.php';
    103                 endforeach;
    104             ?></div><?php
    105 
    106             $podcast = Podcast::create( 9999, array() );
    107             ?><div class="pinecast-feed-template"><?php
    108                 require 'views/podcast-row.php';
    109             ?></div>
    110             <a href="javascript:void(0);" class="button button-secondary" id="pinecast-add-podcast"><?php _e( 'Add another podcast', 'pinecast' ); ?></a>
    111         </div><?php
     100                <div class="pinecast-feeds"><?php
     101                    foreach ( $podcasts as $k => $podcast ) :
     102                        require 'views/podcast-row.php';
     103                    endforeach;
     104                ?></div>
     105                <?php
     106                $podcast = Podcast::create( 9999, array() );
     107                ?>
     108                <div class="pinecast-feed-template"><?php require 'views/podcast-row.php'; ?></div>
     109                <a href="javascript:void(0);" class="button button-secondary" id="pinecast-add-podcast"><?php _e( 'Add another podcast', 'pinecast' ); ?></a>
     110        </div><?php
    112111    }
    113112
  • pinecast-wp-sync/tags/1.1.0/includes/admin/views/podcast-row.php

    r2264272 r2517018  
    99?><div class="pinecast-feed open" data-podcast-id="<?php echo absint( $podcast->get_id() ); ?>">
    1010    <div class="pinecast-feed-header">
    11         <div class="title"><?php
     11        <h2 class="title"><?php
    1212            if ( ! empty( $podcast->get_name() ) ) :
    1313                echo esc_html( $podcast->get_name() );
     
    1515                ?><span class="placeholder"><?php _e( 'Add a new podcast', 'pinecast' ); ?></span><?php
    1616            endif;
    17         ?></div>
    18         <div class="delete"><?php _e( 'Delete', 'pinecast' ); ?></div>
     17        ?></h2>
     18        <button type="button" class="delete"><?php _e( 'Delete', 'pinecast' ); ?></button>
    1919        <div class="handlediv toggle-indicator" title="<?php _e( 'Click to toggle' ); ?>" aria-expanded="true"></div>
    2020    </div>
     
    2424            <div class="label"><?php
    2525                _e( 'Podcast name', 'pinecast' );
    26                 ?><p class="description"><?php _e( 'The name of your podcast as it appears in WordPress settings', 'pinecast' ); ?></p>
     26                ?><p class="description"><?php _e( 'The name of your podcast as it appears here, for your reference', 'pinecast' ); ?></p>
    2727            </div>
    2828            <div class="field">
     
    3838
    3939        <div class="row">
    40             <div class="label"><?php _e( 'Pinecast feed URL', 'pinecast' ); ?></div>
     40            <div class="label"><?php _e( 'Feed URL', 'pinecast' ); ?></div>
    4141            <div class="field">
    4242                <input
     
    4545                    value="<?php echo esc_url( $podcast->get_feed_url() ); ?>"
    4646                    <?php if ($podcast->get_feed_url()) {echo 'readonly';} ?>
    47                     pattern="https?://.+"
     47                    pattern="https://.+"
     48                    placeholder="https://pinecast.com/feed/…"
    4849                    class="otherwise-required"
    4950                    <?php if ($podcast->get_feed_url()) {echo 'required';} ?>
     
    5859            </div>
    5960            <div class="field"><?php
    60                 $category_ids = $podcast->get_category_ids();
     61                $category_ids = $podcast->get_category_ids();
    6162                wp_dropdown_categories( array(
    6263                    'show_option_none' => __( 'Do not assign a category', 'pinecast' ),
     
    6970
    7071        <div class="row">
    71             <div class="label"><?php
    72                 _e( 'Featured image', 'pinecast' );
    73                 ?><p class="description"><?php _e( 'Use the episode artwork as featured image', 'pinecast' ); ?></p>
     72            <div class="label">
     73                <?php _e( 'Featured image', 'pinecast' ); ?>
     74                <p class="description"><?php _e( 'Copy unique episode artwork to WordPress', 'pinecast' ); ?></p>
    7475            </div>
    7576            <div class="field">
    76                 <input name="pinecast_feeds[<?php echo absint( $podcast->get_id() ); ?>][featured_image]" type="checkbox" value="1" <?php checked( $podcast->use_featured_image() ); ?>>
    77             </div>
     77                <input name="pinecast_feeds[<?php echo absint( $podcast->get_id() ); ?>][featured_image]" type="checkbox" value="1" <?php checked( $podcast->use_featured_image() ); ?>>
     78                <label for="pinecast_feeds[<?php echo absint( $podcast->get_id() ); ?>][featured_image]">
     79                    <?php _e( 'Use the episode artwork as featured image', 'pinecast' ); ?>
     80                </label>
     81                <br>
     82                <p class="description">
     83                    <?php _e( 'Since artwork needs to be copied to your server, this option may increase sync times. For shows with many episodes and large artwork files, it may take multiple sync attempts to finish importing artwork.', 'pinecast' ); ?>
     84                </p>
     85            </div>
    7886        </div>
    7987
    8088        <?php if ($podcast->can_sync()) { ?>
    81         <div class="row actions">
    82             <div class="label"><?php _e( 'Actions', 'pinecast' ); ?></div>
    83             <div class="field">
    84                 <a href="javascript:void(0);" <?php disabled( ! $podcast->can_sync() ) ?> class="pinecast-sync-now button button-secondary"><i class="dashicons dashicons-update"></i> <?php _e( 'Refresh feed', 'pinecast' ); ?></a>
    85                 <span class="spinner sync-spinner"></span>
    86                 <br/><span class="description"><?php echo sprintf( __( 'Last updated: %s', 'pinecast' ), '<span class="last-updated">' . ($podcast->get_last_updated() ?? 'Never') ) . '</span>'; ?></span><?php
    87             ?></div>
    88         </div>
     89            <div class="row actions">
     90                <div class="label"><?php _e( 'Actions', 'pinecast' ); ?></div>
     91                <div class="field">
     92                    <a href="javascript:void(0);" <?php disabled( ! $podcast->can_sync() ) ?> class="pinecast-sync-now button button-secondary">
     93                        <i class="dashicons dashicons-update"></i> <?php _e( 'Refresh feed', 'pinecast' ); ?>
     94                    </a>
     95                    <span class="spinner sync-spinner"></span>
     96                    <br>
     97                    <span class="description"><?php echo sprintf( __( 'Last updated: %s', 'pinecast' ), '<span class="last-updated">' . ($podcast->get_last_updated() ?? 'Never') ) . '</span>'; ?></span>
     98                </div>
     99            </div>
    89100        <?php } ?>
    90101
  • pinecast-wp-sync/tags/1.1.0/includes/ajax-functions.php

    r2310548 r2517018  
    1717
    1818    if ( $podcast = get_podcast( wp_unslash($_POST['podcast']) ) ) {
    19         $result = $podcast->sync_episodes();
    20         if ($result) {
    21             wp_send_json( array(
    22                 'success' => false,
    23                 'error' => 'could not sync',
    24                 'result' => $result,
    25                 'feed_url' => $podcast->get_feed_url(),
    26             ) );
    27             return;
    28         }
     19        $podcast->sync_episodes();
     20        $podcast->sync_artwork();
    2921        $podcast
    3022            ->set_last_updated()
  • pinecast-wp-sync/tags/1.1.0/includes/class-podcast.php

    r2473390 r2517018  
    2323    /** @var string Last time the podcast was synced. */
    2424    private $last_updated = null;
     25
     26    /** @var string Synced content of the feed. */
     27    private $feed_data_cache = null;
    2528
    2629
     
    185188     */
    186189    public function get_feed() {
    187         $response = wp_remote_get(
    188             $this->feed_url,
    189             ['user-agent' => 'WordPress; Pinecast Sync Plugin']
    190         );
    191         $body     = wp_remote_retrieve_body( $response );
    192         $body     = json_decode( $body );
     190        if ($this->feed_data_cache) {
     191            $body = $this->feed_data_cache;
     192        } else {
     193            $response = wp_remote_get(
     194                $this->feed_url,
     195                ['user-agent' => 'WordPress; Pinecast Sync Plugin']
     196            );
     197            $body = wp_remote_retrieve_body( $response );
     198        }
     199        $body = json_decode( $body );
    193200
    194201        return $body;
     
    284291     */
    285292    public function can_sync() {
    286         return ! empty( $this->get_feed_url() );
     293        return !empty( $this->get_feed_url() );
    287294    }
    288295
     
    292299     *
    293300     * Synchronize the podcast episodes, create new posts if they don't exist yet.
    294      *
    295      * @return string|bool Returns an error or false
    296301     */
    297302    public function sync_episodes() {
     
    299304
    300305        if ( empty( $feed->items ) ) {
    301             return 'Feed was empty';
     306            return;
    302307        }
    303308
     
    314319            }
    315320        }
    316 
    317         return false;
     321    }
     322
     323    /**
     324     * Synchronize episode artwork.
     325     */
     326    public function sync_artwork() {
     327        $feed = $this->get_feed();
     328
     329        if ( empty( $feed->items ) ) {
     330            return;
     331        }
     332
     333        global $wpdb;
     334        $results = $wpdb->get_results( "SELECT meta_value, post_id FROM {$wpdb->prefix}postmeta WHERE meta_key = '_pinecast_id'", OBJECT_K );
     335        $existing_episode_ids = array_keys( $results );
     336
     337        $start_time = time();
     338        $created_posts = array();
     339        foreach ( $feed->items as $episode ) {
     340            if ( !in_array( $episode->id, $existing_episode_ids ) ) {
     341                continue;
     342            }
     343            if ($this->use_featured_image()){
     344                $this->update_episode_artwork( $episode, $results[$episode->id]->post_id );
     345            } else {
     346                $this->clear_episode_artwork( $results[$episode->id]->post_id );
     347            }
     348
     349            // Short-circuit if this is taking way too long.
     350            $now_time = time();
     351            if ($now_time - $start_time > 25) {
     352                break;
     353            }
     354        }
    318355    }
    319356
     
    361398        }
    362399
    363         if ( $this->use_featured_image() && !empty( $data->image ) ) {
    364             if ( $attachment_id = $this->import_episode_image( $data->image, $post_id, true ) ) {
    365                 set_post_thumbnail( $post_id, $attachment_id );
    366             }
    367         }
    368 
    369400        do_action( 'pinecast/create_episode', $post_id, $data );
    370401
     
    382413    private function update_episode_post( $data, $id ) {
    383414        $post_data = $this->get_post_data($data);
    384         $post_data['ID'] = $id;
    385         if (has_excerpt($id)) {
    386             $post_data['post_excerpt'] = get_the_excerpt($id);
    387         }
     415        $post_data['ID'] = $id;
     416        if (has_excerpt($id)) {
     417            $post_data['post_excerpt'] = get_the_excerpt($id);
     418        }
    388419        $post_id = wp_insert_post( $post_data );
    389420
     
    392423        }
    393424
    394         if ( $this->use_featured_image() ) {
    395             if (!empty($data->image) && $attachment_id = $this->import_episode_image( $data->image, $post_id ) ) {
    396                 set_post_thumbnail( $post_id, $attachment_id );
    397             }
    398         } else {
    399             if (has_post_thumbnail($post_id)) {
    400                 delete_post_thumbnail($post_id);
    401                 delete_post_meta($post_id, '_pinecast_image');
    402             }
    403         }
    404 
    405425        do_action( 'pinecast/update_episode', $post_id, $data );
    406426
     
    410430
    411431    /**
    412      * Import episode image.
    413      *
    414      * Import the featured image to the post of a episode.
    415      *
    416      * @param string $image_url Image URL to import.
    417      * @param int    $post_id ID of the post related to the episode.
    418      * @return bool|int Attachment ID on success, false otherwise.
    419      */
    420     private function import_episode_image( $image_url, $post_id, $override = false ) {
     432     * Update episode's artwork.
     433     *
     434     * @param array $data Data provided through the RSS feed.
     435     * @param int $post_id The ID of the existing post
     436     */
     437    private function update_episode_artwork( $data, $post_id ) {
     438        if (empty($data->image)) {
     439            return;
     440        }
     441        $image_url = $data->image;
     442        $original_image_url = $image_url;
     443
    421444        require_once ABSPATH . 'wp-includes/post.php';
    422445        require_once ABSPATH . 'wp-admin/includes/image.php';
     
    424447        require_once ABSPATH . 'wp-admin/includes/media.php';
    425448
    426         if (!$override) {
    427             $existing_image = get_post_meta($post_id, '_pinecast_image', true);
    428             if ($existing_image === $image_url) {
    429                 // Don't update if it hasn't changed.
    430                 return false;
    431             } elseif ($existing_image) {
    432                 // If there was an existing image that's not the current image, delete it.
    433                 delete_post_thumbnail($post_id);
    434                 delete_post_meta($post_id, '_pinecast_image');
    435             } elseif (has_post_thumbnail($post_id)) {
    436                 // If there was an existing image that's not from Pinecast,
    437                 // don't overwrite it.
    438                 return false;
    439             }
     449        $existing_image = get_post_meta($post_id, '_pinecast_image', true);
     450        if ($existing_image === $image_url) {
     451            // Don't update if it hasn't changed.
     452            return;
     453        } elseif ($existing_image) {
     454            // If there was an existing image that's not the current image, delete it.
     455            delete_post_thumbnail($post_id);
     456            delete_post_meta($post_id, '_pinecast_image');
     457        } elseif (has_post_thumbnail($post_id)) {
     458            // If there was an existing image that's not from Pinecast,
     459            // don't overwrite it.
     460            return;
     461        }
     462
     463        // Rewrite the image URL to use the cropped version from the CDN, if it's
     464        // using the Pinecast CDN.
     465        if (strpos($image_url, 'https://storage.pinecast.net/podcasts/') === 0) {
     466            $image_url = str_replace(
     467                'https://storage.pinecast.net/podcasts/',
     468                'https://storage.pinecast.net/cdn-cgi/image/w=1280,h=1280,fit=scale-down,anim=false,onerror=redirect,metadata=none/podcasts/',
     469                $image_url
     470            );
    440471        }
    441472
    442473        // Download file to temp dir
    443         $temp_file = download_url( $image_url, $timeout_seconds = 5 );
    444 
    445         if ( ! is_wp_error( $temp_file ) ) {
    446             $file = array(
    447                 'name'     => basename( $image_url ),
    448                 'type'     => mime_content_type( $temp_file ),
    449                 'tmp_name' => $temp_file,
    450                 'error'    => 0,
    451                 'size'     => filesize( $temp_file ),
    452             );
    453 
    454             // Move temporary file to uploads directory
    455             $attachment_id = media_handle_sideload( $file, $post_id );
    456 
    457             update_post_meta($post_id, '_pinecast_image', $image_url);
    458 
    459             return $attachment_id;
    460         }
    461 
    462         return false;
     474        $temp_file = download_url( $image_url, $timeout_seconds = 10 );
     475        if ( is_wp_error( $temp_file ) ) {
     476            return;
     477        }
     478
     479        $file = array(
     480            'name'     => basename( $image_url ),
     481            'type'     => mime_content_type( $temp_file ),
     482            'tmp_name' => $temp_file,
     483            'error'    => 0,
     484            'size'     => filesize( $temp_file ),
     485        );
     486
     487        // Move temporary file to uploads directory
     488        $attachment_id = media_handle_sideload( $file, $post_id );
     489
     490        update_post_meta($post_id, '_pinecast_image', $original_image_url);
     491        set_post_thumbnail( $post_id, $attachment_id );
     492        do_action( 'pinecast/update_episode_artwork', $post_id );
     493    }
     494
     495    /**
     496     * Clear episode's artwork.
     497     *
     498     * @param int $post_id The ID of the existing post
     499     */
     500    private function clear_episode_artwork( $post_id ) {
     501        // Delete the post image if there's a thumbnail and it's from Pinecast.
     502        if (has_post_thumbnail($post_id) && get_post_meta($post_id, '_pinecast_image', true)) {
     503            delete_post_thumbnail($post_id);
     504            delete_post_meta($post_id, '_pinecast_image');
     505            do_action( 'pinecast/clear_episode_artwork', $post_id);
     506        }
    463507    }
    464508}
  • pinecast-wp-sync/tags/1.1.0/includes/cron-functions.php

    r2339437 r2517018  
    2323 */
    2424function check_podcast_sync() {
     25    $start_time = time();
     26
    2527    $podcasts = get_podcasts();
    2628
     
    3133    });
    3234
     35    // First, sync episodes. This creates and updates posts with content and metadata.
    3336    array_walk( $podcasts, function( $podcast ) {
    3437        /** @var Podcast $podcast */
     
    3841            ->update();
    3942    } );
     43    // After, we walk the podcasts again and sync artwork. This done separately, in case
     44    // artwork download causes timeouts.
     45    array_walk( $podcasts, function( $podcast ) use ($start_time) {
     46        /** @var Podcast $podcast */
     47
     48        // If we're taking too long, abort artwork sync early.
     49        $now_time = time();
     50        if ($now_time - $start_time > 25) {
     51            return;
     52        }
     53
     54        $podcast->sync_artwork();
     55
     56        $podcast->set_last_updated()
     57            ->update();
     58
     59    } );
    4060}
    4161add_action( 'pinecast/feed_sync', '\Pinecast\check_podcast_sync' );
  • pinecast-wp-sync/tags/1.1.0/package-lock.json

    r2473390 r2517018  
    11{
    22  "name": "pinecast",
    3   "version": "1.0.14",
     3  "version": "1.1.0",
    44  "lockfileVersion": 1,
    55  "requires": true,
  • pinecast-wp-sync/tags/1.1.0/package.json

    r2473390 r2517018  
    11{
    22  "name": "pinecast",
    3   "version": "1.0.14",
     3  "version": "1.1.0",
    44  "description": "",
    55  "main": "gulpfile.js",
  • pinecast-wp-sync/tags/1.1.0/pinecast.php

    r2473390 r2517018  
    88
    99        /** @var string Plugin version */
    10         public $version = '1.0.14';
     10        public $version = '1.1.0';
    1111
    1212        /** @var string Main plugin file */
  • pinecast-wp-sync/tags/1.1.0/plugin.php

    r2473390 r2517018  
    44 * Plugin URI:      https://help.pinecast.com/articles/3072843-pinecast-wordpress-sync-plugin
    55 * Description:     Sync your Pinecast podcast episodes from Pinecast to WordPress
    6  * Version:         1.0.14
     6 * Version:         1.1.0
    77 * Author:          Pinecast
    88 * Author URI:      https://pinecast.com
  • pinecast-wp-sync/tags/1.1.0/readme.txt

    r2473390 r2517018  
    33Tags: pinecast, sync, jsonfeed, podcast
    44Requires at least: 5.2
    5 Tested up to: 5.6
    6 Stable tag: 1.0.14
     5Tested up to: 5.7
     6Stable tag: 1.1.0
    77Requires PHP: 7.0
    88License: GPLv2 or later
     
    1515This plugin allows you to sync your Pinecast podcast (or any JSONFeed-compatible podcast) with your WordPress blog.
    1616
    17 Please see Pinecast's [support website](https://help.pinecast.com/en/articles/3072843-pinecast-wordpress-sync-plugin) for more information.
     17Please see Pinecast's [support website](https://pinecast.support/en/articles/3072843-pinecast-wordpress-sync-plugin) for more information.
    1818
    1919After installing, visit Settings > Pinecast to add feeds. Add your Pinecast RSS feed URL (found on your podcast dashboard), along with the podcast's name (for your reference), categories that you wish to be applied to each episode's post, and whether you'd like to include episode artwork in the posts. Save changes.
     
    2828
    2929== Changelog ==
     30
     31= 1.1.0 =
     32* New two-phase sync algorithm prioritizes episode creation over artwork download, preventing sync timeout errors from blocking episode creation
     33* Very large episode artwork is resized/re-encoded to save space and improve sync times.
     34* Accessibility improvements on the settings page
     35* Better wording on settings page options
    3036
    3137= 1.0.13 =
  • pinecast-wp-sync/trunk/dist/admin/css/pinecast.min.css

    r2120413 r2517018  
    1 #pinecast-add-podcast{margin-top:10px}.pinecast-feed-template{display:none}.pinecast-feed{background:#fff}.pinecast-feed .pinecast-feed-header{display:flex;flex-grow:1;height:30px;cursor:pointer;font-size:14px;padding:12px 7px 12px 12px;line-height:30px;font-weight:600;border-bottom:1px solid #eee}.pinecast-feed .pinecast-feed-header .title{flex-grow:1}.pinecast-feed .pinecast-feed-header .title .placeholder{color:#999}.pinecast-feed .pinecast-feed-header .delete{color:#a00;line-height:20px;vertical-align:middle;font-size:13px;margin-right:1em;height:20px;margin-top:5px;margin-bottom:5px;display:inline-block;font-weight:normal;visibility:hidden}.pinecast-feed .pinecast-feed-header .delete:hover{color:#dc3232}.pinecast-feed .pinecast-feed-header .handlediv{width:36px;display:block;justify-self:flex-end;height:36px;margin:0;padding:0;border:0;background:none;cursor:pointer}.pinecast-feed .pinecast-feed-header .handlediv:before{content:"\f141";display:inline-block;font:normal 20px/1 dashicons;speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-decoration:none !important;padding:0;right:0;vertical-align:middle}.pinecast-feed .pinecast-feed-header:hover .delete{visibility:visible}.pinecast-feed .pinecast-feed-body{display:none;background:#f9f9f9;border-bottom:1px solid #eee}.pinecast-feed .pinecast-feed-body .row{display:flex;flex-direction:row;width:100%}.pinecast-feed .pinecast-feed-body .row .label{border-color:#e5e5e5;border-width:0 1px 1px 0;border-style:solid;padding:15px 10px;font-weight:bold;background:#F9F9F9;width:200px}.pinecast-feed .pinecast-feed-body .row .field{padding:15px 10px;width:100%;border-bottom:1px solid #e5e5e5;background:#fff}.pinecast-feed .pinecast-feed-body .row .field input,.pinecast-feed .pinecast-feed-body .row .field textarea,.pinecast-feed .pinecast-feed-body .row .field select{width:100%;box-sizing:border-box;font-size:14px;line-height:1.4}.pinecast-feed .pinecast-feed-body .row .field input[type='radio'],.pinecast-feed .pinecast-feed-body .row .field input[type='checkbox']{width:auto !important}.pinecast-feed .pinecast-feed-body .row:last-of-type .label,.pinecast-feed .pinecast-feed-body .row:last-of-type .field{border-bottom:none}.pinecast-feed .pinecast-feed-body .row .description{color:#788;font-size:12px;font-weight:normal}.pinecast-feed .pinecast-feed-body .row.actions{background:red !important}.pinecast-feed .pinecast-feed-body .row.actions .button .dashicons{line-height:27px;height:27px}.pinecast-feed.open .pinecast-feed-body{display:block}.pinecast-feed.open .handlediv:before{content:'\f140'}.spinner{float:none}
     1#pinecast-add-podcast{margin-top:10px}.pinecast-feed-template{display:none}.pinecast-feed{background:#fff}.pinecast-feed .pinecast-feed-header{display:flex;flex-grow:1;height:30px;cursor:pointer;font-size:14px;padding:12px 7px 12px 12px;line-height:30px;font-weight:600;border-bottom:1px solid #eee}.pinecast-feed .pinecast-feed-header .title{flex-grow:1;font-size:14px;font-weight:400;line-height:1em;margin:0}.pinecast-feed .pinecast-feed-header .title .placeholder{color:#999}.pinecast-feed .pinecast-feed-header .delete{appearance:none;background:transparent;border:0;color:#a00;display:inline-block;font-size:13px;font-weight:normal;height:20px;line-height:20px;margin-bottom:5px;margin-right:1em;margin-top:5px;vertical-align:middle;visibility:hidden}.pinecast-feed .pinecast-feed-header .delete:hover{color:#dc3232}.pinecast-feed .pinecast-feed-header .handlediv{width:36px;display:block;justify-self:flex-end;height:36px;margin:0;padding:0;border:0;background:none;cursor:pointer}.pinecast-feed .pinecast-feed-header .handlediv:before{content:"\f141";display:inline-block;font:normal 20px/1 dashicons;speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-decoration:none !important;padding:0;right:0;vertical-align:middle}.pinecast-feed .pinecast-feed-header:hover .delete{visibility:visible}.pinecast-feed .pinecast-feed-body{display:none;background:#f9f9f9;border-bottom:1px solid #eee}.pinecast-feed .pinecast-feed-body .row{display:flex;flex-direction:row;width:100%}.pinecast-feed .pinecast-feed-body .row .label{border-color:#e5e5e5;border-width:0 1px 1px 0;border-style:solid;padding:15px 10px;font-weight:bold;background:#F9F9F9;width:200px}.pinecast-feed .pinecast-feed-body .row .field{padding:15px 10px;width:100%;border-bottom:1px solid #e5e5e5;background:#fff}.pinecast-feed .pinecast-feed-body .row .field input,.pinecast-feed .pinecast-feed-body .row .field textarea,.pinecast-feed .pinecast-feed-body .row .field select{width:100%;box-sizing:border-box;font-size:14px;line-height:1.4}.pinecast-feed .pinecast-feed-body .row .field input[type='radio'],.pinecast-feed .pinecast-feed-body .row .field input[type='checkbox']{width:auto !important}.pinecast-feed .pinecast-feed-body .row:last-of-type .label,.pinecast-feed .pinecast-feed-body .row:last-of-type .field{border-bottom:none}.pinecast-feed .pinecast-feed-body .row .description{color:#788;font-size:12px;font-weight:normal}.pinecast-feed .pinecast-feed-body .row.actions{background:red !important}.pinecast-feed .pinecast-feed-body .row.actions .button .dashicons{line-height:27px;height:27px}.pinecast-feed.open .pinecast-feed-body{display:block}.pinecast-feed.open .handlediv:before{content:'\f140'}.spinner{float:none}
    22
    33/*# sourceMappingURL=pinecast.min.css.map */
  • pinecast-wp-sync/trunk/dist/admin/css/pinecast.min.css.map

    r2120413 r2517018  
    1 {"version":3,"file":"pinecast.min.css","sources":["pinecast.scss"],"sourcesContent":["#pinecast-add-podcast {\n\tmargin-top: 10px;\n}\n\n\n.pinecast-feed-template {\n\tdisplay: none;\n}\n.pinecast-feed {\n\tbackground: #fff;\n\n\t// Header\n\t.pinecast-feed-header {\n\t\tdisplay: flex;\n\t\tflex-grow: 1;\n\t\theight: 30px;\n\t\tcursor: pointer;\n\t\tfont-size: 14px;\n\t\tpadding: 12px 7px 12px 12px;\n\t\tline-height: 30px;\n\t\tfont-weight: 600;\n\t\tborder-bottom: 1px solid #eee;\n\n\t\t.title {\n\t\t\tflex-grow: 1;\n\n\t\t\t.placeholder {\n\t\t\t\tcolor: #999;\n\t\t\t}\n\t\t}\n\t\t.delete {\n\t\t\tcolor: #a00;\n\t\t\tline-height: 20px;\n\t\t\tvertical-align: middle;\n\t\t\tfont-size: 13px;\n\t\t\tmargin-right: 1em;\n\t\t\theight: 20px;\n\t\t\tmargin-top: 5px;\n\t\t\tmargin-bottom: 5px;\n\t\t\tdisplay: inline-block;\n\t\t\tfont-weight: normal;\n\t\t\tvisibility: hidden;\n\n\t\t\t&:hover {\n\t\t\t\tcolor: #dc3232;\n\t\t\t}\n\t\t}\n\n\t\t.handlediv {\n\t\t\twidth: 36px;\n\t\t\tdisplay: block;\n\t\t\tjustify-self: flex-end;\n\t\t\theight: 36px;\n\t\t\tmargin: 0;\n\t\t\tpadding: 0;\n\t\t\tborder: 0;\n\t\t\tbackground: none;\n\t\t\tcursor: pointer;\n\n\t\t\t&:before {\n\t\t\t\tcontent: \"\\f141\";\n\t\t\t\tdisplay: inline-block;\n\t\t\t\tfont: normal 20px/1 dashicons;\n\t\t\t\tspeak: none;\n\t\t\t\t-webkit-font-smoothing: antialiased;\n\t\t\t\t-moz-osx-font-smoothing: grayscale;\n\t\t\t\ttext-decoration: none !important;\n\t\t\t\tpadding: 0;\n\t\t\t\tright: 0;\n\t\t\t\tvertical-align: middle;\n\t\t\t}\n\t\t}\n\n\t\t&:hover {\n\n\t\t\t.delete {\n\t\t\t\tvisibility: visible;\n\t\t\t}\n\t\t}\n\t}\n\t.pinecast-feed-body {\n\t\tdisplay: none;\n\n\t\tbackground: #f9f9f9;\n\t\t//padding: 12px;\n\t\tborder-bottom: 1px solid #eee;\n\n\t\t.row {\n\t\t\tdisplay: flex;\n\t\t\tflex-direction: row;\n\t\t\twidth: 100%;\n\n\t\t\t.label {\n\t\t\t\tborder-color: #e5e5e5;\n\t\t\t\tborder-width: 0 1px 1px 0;\n\t\t\t\tborder-style: solid;\n\t\t\t\tpadding: 15px 10px;\n\t\t\t\tfont-weight: bold;\n\t\t\t\tbackground: #F9F9F9;\n\t\t\t\twidth: 200px;\n\t\t\t}\n\t\t\t.field {\n\t\t\t\tpadding: 15px 10px;\n\t\t\t\twidth: 100%;\n\t\t\t\tborder-bottom: 1px solid #e5e5e5;\n\t\t\t\tbackground: #fff;\n\n\t\t\t\tinput,\n\t\t\t\ttextarea,\n\t\t\t\tselect {\n\t\t\t\t\twidth: 100%;\n\t\t\t\t\tbox-sizing: border-box;\n\t\t\t\t\tfont-size: 14px;\n\t\t\t\t\tline-height: 1.4;\n\t\t\t\t}\n\t\t\t\tinput[type='radio'],\n\t\t\t\tinput[type='checkbox'] {\n\t\t\t\t\twidth: auto !important;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&:last-of-type {\n\t\t\t\t.label, .field {\n\t\t\t\t\tborder-bottom: none;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t.description {\n\t\t\t\tcolor: #788;\n\t\t\t\tfont-size: 12px;\n\t\t\t\tfont-weight: normal;\n\t\t\t}\n\t\t}\n\n\t\t/** Element specific */\n\t\t.row.actions {\n\t\t\tbackground: red !important;\n\t\t\t.button {\n\n\t\t\t\t.dashicons {\n\t\t\t\t\tline-height: 27px;\n\t\t\t\t\theight: 27px;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t&.open {\n\n\t\t.pinecast-feed-body {\n\t\t\tdisplay: block;\n\t\t}\n\t\t.handlediv:before {\n\t\t\tcontent: '\\f140';\n\t\t}\n\t}\n}\n\n\n.spinner {\n\tfloat: none;\n}\n"],"names":[],"mappings":"AAAA,AAAA,qBAAqB,AAAC,CACrB,UAAU,CAAE,IAAI,CAChB,AAGD,AAAA,uBAAuB,AAAC,CACvB,OAAO,CAAE,IAAI,CACb,AACD,AAAA,cAAc,AAAC,CACd,UAAU,CAAE,IAAI,CAkJhB,AAnJD,AAIC,cAJa,CAIb,qBAAqB,AAAC,CACrB,OAAO,CAAE,IAAI,CACb,SAAS,CAAE,CAAC,CACZ,MAAM,CAAE,IAAI,CACZ,MAAM,CAAE,OAAO,CACf,SAAS,CAAE,IAAI,CACf,OAAO,CAAE,kBAAkB,CAC3B,WAAW,CAAE,IAAI,CACjB,WAAW,CAAE,GAAG,CAChB,aAAa,CAAE,cAAc,CA0D7B,AAvEF,AAeE,cAfY,CAIb,qBAAqB,CAWpB,MAAM,AAAC,CACN,SAAS,CAAE,CAAC,CAKZ,AArBH,AAkBG,cAlBW,CAIb,qBAAqB,CAWpB,MAAM,CAGL,YAAY,AAAC,CACZ,KAAK,CAAE,IAAI,CACX,AApBJ,AAsBE,cAtBY,CAIb,qBAAqB,CAkBpB,OAAO,AAAC,CACP,KAAK,CAAE,IAAI,CACX,WAAW,CAAE,IAAI,CACjB,cAAc,CAAE,MAAM,CACtB,SAAS,CAAE,IAAI,CACf,YAAY,CAAE,GAAG,CACjB,MAAM,CAAE,IAAI,CACZ,UAAU,CAAE,GAAG,CACf,aAAa,CAAE,GAAG,CAClB,OAAO,CAAE,YAAY,CACrB,WAAW,CAAE,MAAM,CACnB,UAAU,CAAE,MAAM,CAKlB,AAtCH,AAmCG,cAnCW,CAIb,qBAAqB,CAkBpB,OAAO,AAaL,MAAM,AAAC,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AU,AAAC,CACV,WAAW,CAAE,IAAI,CACjB,MAAM,CAAE,IAAI,CACZ,AAtIL,AA4IE,cA5IY,AA0IZ,KAAK,CAEL,mBAAmB,AAAC,CACnB,OAAO,CAAE,KAAK,CACd,AA9IH,AA+IE,cA/IY,AA0IZ,KAAK,CAKL,UAAU,AAAA,OAAO,AAAC,CACjB,OAAO,CAAE,OAAO,CAChB,AAKH,AAAA,QAAQ,AAAC,CACR,KAAK,CAAE,IAAI,CACX"}
     1{"version":3,"file":"pinecast.min.css","sources":["pinecast.scss"],"sourcesContent":["#pinecast-add-podcast {\n\tmargin-top: 10px;\n}\n\n\n.pinecast-feed-template {\n\tdisplay: none;\n}\n.pinecast-feed {\n\tbackground: #fff;\n\n\t// Header\n\t.pinecast-feed-header {\n\t\tdisplay: flex;\n\t\tflex-grow: 1;\n\t\theight: 30px;\n\t\tcursor: pointer;\n\t\tfont-size: 14px;\n\t\tpadding: 12px 7px 12px 12px;\n\t\tline-height: 30px;\n\t\tfont-weight: 600;\n\t\tborder-bottom: 1px solid #eee;\n\n\t\t.title {\n\t\t\tflex-grow: 1;\n\t\t\tfont-size: 14px;\n\t\t\tfont-weight: 400;\n\t\t\tline-height: 1em;\n\t\t\tmargin: 0;\n\n\t\t\t.placeholder {\n\t\t\t\tcolor: #999;\n\t\t\t}\n\t\t}\n\t\t.delete {\n\t\t\tappearance: none;\n\t\t\tbackground: transparent;\n\t\t\tborder: 0;\n\t\t\tcolor: #a00;\n\t\t\tdisplay: inline-block;\n\t\t\tfont-size: 13px;\n\t\t\tfont-weight: normal;\n\t\t\theight: 20px;\n\t\t\tline-height: 20px;\n\t\t\tmargin-bottom: 5px;\n\t\t\tmargin-right: 1em;\n\t\t\tmargin-top: 5px;\n\t\t\tvertical-align: middle;\n\t\t\tvisibility: hidden;\n\n\t\t\t&:hover {\n\t\t\t\tcolor: #dc3232;\n\t\t\t}\n\t\t}\n\n\t\t.handlediv {\n\t\t\twidth: 36px;\n\t\t\tdisplay: block;\n\t\t\tjustify-self: flex-end;\n\t\t\theight: 36px;\n\t\t\tmargin: 0;\n\t\t\tpadding: 0;\n\t\t\tborder: 0;\n\t\t\tbackground: none;\n\t\t\tcursor: pointer;\n\n\t\t\t&:before {\n\t\t\t\tcontent: \"\\f141\";\n\t\t\t\tdisplay: inline-block;\n\t\t\t\tfont: normal 20px/1 dashicons;\n\t\t\t\tspeak: none;\n\t\t\t\t-webkit-font-smoothing: antialiased;\n\t\t\t\t-moz-osx-font-smoothing: grayscale;\n\t\t\t\ttext-decoration: none !important;\n\t\t\t\tpadding: 0;\n\t\t\t\tright: 0;\n\t\t\t\tvertical-align: middle;\n\t\t\t}\n\t\t}\n\n\t\t&:hover {\n\t\t\t.delete {\n\t\t\t\tvisibility: visible;\n\t\t\t}\n\t\t}\n\t}\n\t.pinecast-feed-body {\n\t\tdisplay: none;\n\n\t\tbackground: #f9f9f9;\n\t\t//padding: 12px;\n\t\tborder-bottom: 1px solid #eee;\n\n\t\t.row {\n\t\t\tdisplay: flex;\n\t\t\tflex-direction: row;\n\t\t\twidth: 100%;\n\n\t\t\t.label {\n\t\t\t\tborder-color: #e5e5e5;\n\t\t\t\tborder-width: 0 1px 1px 0;\n\t\t\t\tborder-style: solid;\n\t\t\t\tpadding: 15px 10px;\n\t\t\t\tfont-weight: bold;\n\t\t\t\tbackground: #F9F9F9;\n\t\t\t\twidth: 200px;\n\t\t\t}\n\t\t\t.field {\n\t\t\t\tpadding: 15px 10px;\n\t\t\t\twidth: 100%;\n\t\t\t\tborder-bottom: 1px solid #e5e5e5;\n\t\t\t\tbackground: #fff;\n\n\t\t\t\tinput,\n\t\t\t\ttextarea,\n\t\t\t\tselect {\n\t\t\t\t\twidth: 100%;\n\t\t\t\t\tbox-sizing: border-box;\n\t\t\t\t\tfont-size: 14px;\n\t\t\t\t\tline-height: 1.4;\n\t\t\t\t}\n\t\t\t\tinput[type='radio'],\n\t\t\t\tinput[type='checkbox'] {\n\t\t\t\t\twidth: auto !important;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&:last-of-type {\n\t\t\t\t.label, .field {\n\t\t\t\t\tborder-bottom: none;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t.description {\n\t\t\t\tcolor: #788;\n\t\t\t\tfont-size: 12px;\n\t\t\t\tfont-weight: normal;\n\t\t\t}\n\t\t}\n\n\t\t/** Element specific */\n\t\t.row.actions {\n\t\t\tbackground: red !important;\n\t\t\t.button {\n\n\t\t\t\t.dashicons {\n\t\t\t\t\tline-height: 27px;\n\t\t\t\t\theight: 27px;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t&.open {\n\n\t\t.pinecast-feed-body {\n\t\t\tdisplay: block;\n\t\t}\n\t\t.handlediv:before {\n\t\t\tcontent: '\\f140';\n\t\t}\n\t}\n}\n\n\n.spinner {\n\tfloat: none;\n}\n"],"names":[],"mappings":"AAAA,AAAA,qBAAqB,AAAC,CACrB,UAAU,CAAE,IAAI,CAChB,AAGD,AAAA,uBAAuB,AAAC,CACvB,OAAO,CAAE,IAAI,CACb,AACD,AAAA,cAAc,AAAC,CACd,UAAU,CAAE,IAAI,CAwJhB,AAzJD,AAIC,cAJa,CAIb,qBAAqB,AAAC,CACrB,OAAO,CAAE,IAAI,CACb,SAAS,CAAE,CAAC,CACZ,MAAM,CAAE,IAAI,CACZ,MAAM,CAAE,OAAO,CACf,SAAS,CAAE,IAAI,CACf,OAAO,CAAE,kBAAkB,CAC3B,WAAW,CAAE,IAAI,CACjB,WAAW,CAAE,GAAG,CAChB,aAAa,CAAE,cAAc,CAgE7B,AA7EF,AAeE,cAfY,CAIb,qBAAqB,CAWpB,MAAM,AAAC,CACN,SAAS,CAAE,CAAC,CACZ,SAAS,CAAE,IAAI,CACf,WAAW,CAAE,GAAG,CAChB,WAAW,CAAE,GAAG,CAChB,MAAM,CAAE,CAAC,CAKT,AAzBH,AAsBG,cAtBW,CAIb,qBAAqB,CAWpB,MAAM,CAOL,YAAY,AAAC,CACZ,KAAK,CAAE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,CA8Eb,mBAAmB,CAOlB,IAAI,AAkCF,aAAa,CACb,MAAM,CAxHV,cAAc,CA8Eb,mBAAmB,CAOlB,IAAI,AAkCF,aAAa,CACL,MAAM,AAAC,CACd,aAAa,CAAE,IAAI,CACnB,AA1HL,AA6HG,cA7HW,CA8Eb,mBAAmB,CAOlB,IAAI,CAwCH,YAAY,AAAC,CACZ,KAAK,CAAE,IAAI,CACX,SAAS,CAAE,IAAI,CACf,WAAW,CAAE,MAAM,CACnB,AAjIJ,AAqIE,cArIY,CA8Eb,mBAAmB,CAuDlB,IAAI,AAAA,QAAQ,AAAC,CACZ,UAAU,CAAE,cAAc,CAQ1B,AA9IH,AAyII,cAzIU,CA8Eb,mBAAmB,CAuDlB,IAAI,AAAA,QAAQ,CAEX,OAAO,CAEN,UAAU,AAAC,CACV,WAAW,CAAE,IAAI,CACjB,MAAM,CAAE,IAAI,CACZ,AA5IL,AAkJE,cAlJY,AAgJZ,KAAK,CAEL,mBAAmB,AAAC,CACnB,OAAO,CAAE,KAAK,CACd,AApJH,AAqJE,cArJY,AAgJZ,KAAK,CAKL,UAAU,AAAA,OAAO,AAAC,CACjB,OAAO,CAAE,OAAO,CAChB,AAKH,AAAA,QAAQ,AAAC,CACR,KAAK,CAAE,IAAI,CACX"}
  • pinecast-wp-sync/trunk/includes/admin/settings.php

    r2423119 r2517018  
    6464        ?><div class="wrap">
    6565
    66 <!--            <h1>Pinecast</h1>-->
    67             <svg width="122" height="19" xmlns="http://www.w3.org/2000/svg" style="padding: 15px 0 4px 0;"><g fill="none" fill-rule="evenodd"><path d="M41.99 17h-2.48V2.8h4.96c3.08 0 5.04 1.72 5.04 4.42 0 2.74-1.94 4.46-5.04 4.46h-2.48V17zm0-7.44h2.34c1.72 0 2.7-.84 2.7-2.3s-.98-2.3-2.7-2.3h-2.34v4.6zM53.69 17h-2.4V6.6h2.4V17zm.24-13.12c0 .82-.6 1.44-1.44 1.44-.82 0-1.44-.62-1.44-1.44 0-.84.62-1.44 1.44-1.44.84 0 1.44.6 1.44 1.44zM58.55 17h-2.4V6.6h2.4v1.04c.88-.88 1.94-1.32 3.16-1.32 2.24 0 3.56 1.46 3.56 3.92V17h-2.4v-6.36c0-1.46-.66-2.24-1.9-2.24-.86 0-1.72.44-2.42 1.22V17zm18.02-4.34h-7c.24 1.72 1.16 2.62 2.68 2.62 1 0 1.98-.4 2.9-1.16l1.06 1.7a6.23 6.23 0 0 1-4.04 1.46c-3.1 0-5.04-2.08-5.04-5.42 0-3.32 1.94-5.54 4.84-5.54 2.8 0 4.6 2.1 4.6 5.42v.92zM71.93 8.2c-1.36 0-2.3 1.14-2.36 2.82h4.64c-.06-1.72-.94-2.82-2.28-2.82zm12.9 5.12l2.08 1.06c-.88 1.84-2.48 2.9-4.38 2.9-2.82 0-4.74-2.22-4.74-5.44 0-3.26 2-5.52 4.88-5.52 1.9 0 3.38.98 4.2 2.76l-2.1 1.02c-.44-1.12-1.16-1.7-2.12-1.7-1.5 0-2.46 1.34-2.46 3.4 0 2.04.94 3.4 2.36 3.4.96 0 1.76-.66 2.28-1.88zm7.8-4.96c-1.06 0-2.18.32-3.48 1l-.72-1.94c1.62-.76 3.06-1.1 4.54-1.1 2.68 0 3.96 1.18 3.96 3.64v3.62c0 1.48.14 1.98.72 2.44l-1.54 1.26c-.7-.28-1.12-.66-1.34-1.18-.9.8-1.88 1.18-3.02 1.18-2.22 0-3.7-1.36-3.7-3.4 0-2.28 1.7-3.18 6.48-3.4v-.46c0-1.14-.6-1.66-1.9-1.66zm-.18 7.08c.78 0 1.46-.28 2.08-.86v-2.5c-3.28.28-4.08.62-4.08 1.74 0 1 .78 1.62 2 1.62zm6.9-5.82c0-1.94 1.58-3.3 3.86-3.3 1.28 0 2.58.42 3.82 1.24l-1.16 1.8c-1.02-.72-1.9-1.08-2.66-1.08-.84 0-1.46.44-1.46 1.08 0 1.88 5.52.84 5.52 4.52 0 2.02-1.66 3.4-4.08 3.4-1.46 0-3-.5-4.36-1.44l1.2-1.78c1.16.84 2.22 1.26 3.2 1.26 1 0 1.64-.44 1.64-1.12 0-1.98-5.52-.96-5.52-4.58zm8.86-1.14V6.6h1.84V3.8l2.4-.48V6.6h2.8v1.88h-2.8v5.26c0 .94.42 1.38 1.3 1.38.4 0 .92-.1 1.38-.26l.36 1.84c-.92.3-1.74.46-2.46.46-1.92 0-2.98-1.06-2.98-3.02V8.48h-1.84z" fill="#3F3F3F"/><g fill="#1FD2C4"><path d="M7.03 16.09h17.818a9.84 9.84 0 0 0 .1-6.39c-.798-2.454-2.485-4.443-4.752-5.603a9.258 9.258 0 0 0-7.245-.535c-4.968 1.68-7.669 7.167-6.021 12.233.032.099.065.197.1.295m23.595 2.452H6.245c-.425 0-.818-.23-1.034-.601l-.071-.121a1.372 1.372 0 0 1-.064-.127c-.16-.367-.305-.746-.428-1.126-2.065-6.349 1.32-13.227 7.545-15.333a11.615 11.615 0 0 1 9.081.672c2.84 1.453 4.955 3.947 5.956 7.022.76 2.337.804 4.826.146 7.162h3.249c.664 0 1.202.55 1.202 1.226 0 .676-.538 1.226-1.202 1.226"/><path d="M17.141 12.893c0 .677-.538 1.225-1.202 1.225a1.214 1.214 0 0 1-1.202-1.225c0-.678.538-1.226 1.202-1.226.664 0 1.202.548 1.202 1.226"/><path d="M9.881 14.118c-.66 0-1.196-.541-1.202-1.215a7.56 7.56 0 0 1 .95-3.729 7.281 7.281 0 0 1 4.408-3.509 7.136 7.136 0 0 1 5.55.698 7.295 7.295 0 0 1 2.123 1.85c.412.53.325 1.3-.195 1.721a1.186 1.186 0 0 1-1.689-.198 4.907 4.907 0 0 0-1.424-1.24 4.792 4.792 0 0 0-3.724-.468 4.887 4.887 0 0 0-2.957 2.354 5.065 5.065 0 0 0-.638 2.5 1.215 1.215 0 0 1-1.192 1.236h-.01zM1.202 18.602C.54 18.602 0 18.052 0 17.376c0-.677.539-1.226 1.202-1.226h1.503c.663 0 1.202.55 1.202 1.226 0 .676-.539 1.226-1.202 1.226H1.202z"/></g><path d="M118.496 15.443H118V15h1.488v.443h-.496V17h-.496v-1.557zM119.97 15h.514l.294.83.103.327h.012l.104-.326.282-.831h.513v2h-.46v-.59c0-.052.002-.108.006-.17a17.151 17.151 0 0 1 .036-.378l.02-.167h-.011l-.156.468-.26.674h-.184l-.26-.674-.149-.468h-.012l.02.167a5.393 5.393 0 0 1 .037.378c.004.062.007.118.007.17V17h-.456v-2z" fill="#2C253C"/></g></svg><?php
     66      <h1 aria-label="Pinecast"><svg width="122" height="19" xmlns="http://www.w3.org/2000/svg" style="padding: 15px 0 4px 0;"><g fill="none" fill-rule="evenodd"><path d="M41.99 17h-2.48V2.8h4.96c3.08 0 5.04 1.72 5.04 4.42 0 2.74-1.94 4.46-5.04 4.46h-2.48V17zm0-7.44h2.34c1.72 0 2.7-.84 2.7-2.3s-.98-2.3-2.7-2.3h-2.34v4.6zM53.69 17h-2.4V6.6h2.4V17zm.24-13.12c0 .82-.6 1.44-1.44 1.44-.82 0-1.44-.62-1.44-1.44 0-.84.62-1.44 1.44-1.44.84 0 1.44.6 1.44 1.44zM58.55 17h-2.4V6.6h2.4v1.04c.88-.88 1.94-1.32 3.16-1.32 2.24 0 3.56 1.46 3.56 3.92V17h-2.4v-6.36c0-1.46-.66-2.24-1.9-2.24-.86 0-1.72.44-2.42 1.22V17zm18.02-4.34h-7c.24 1.72 1.16 2.62 2.68 2.62 1 0 1.98-.4 2.9-1.16l1.06 1.7a6.23 6.23 0 0 1-4.04 1.46c-3.1 0-5.04-2.08-5.04-5.42 0-3.32 1.94-5.54 4.84-5.54 2.8 0 4.6 2.1 4.6 5.42v.92zM71.93 8.2c-1.36 0-2.3 1.14-2.36 2.82h4.64c-.06-1.72-.94-2.82-2.28-2.82zm12.9 5.12l2.08 1.06c-.88 1.84-2.48 2.9-4.38 2.9-2.82 0-4.74-2.22-4.74-5.44 0-3.26 2-5.52 4.88-5.52 1.9 0 3.38.98 4.2 2.76l-2.1 1.02c-.44-1.12-1.16-1.7-2.12-1.7-1.5 0-2.46 1.34-2.46 3.4 0 2.04.94 3.4 2.36 3.4.96 0 1.76-.66 2.28-1.88zm7.8-4.96c-1.06 0-2.18.32-3.48 1l-.72-1.94c1.62-.76 3.06-1.1 4.54-1.1 2.68 0 3.96 1.18 3.96 3.64v3.62c0 1.48.14 1.98.72 2.44l-1.54 1.26c-.7-.28-1.12-.66-1.34-1.18-.9.8-1.88 1.18-3.02 1.18-2.22 0-3.7-1.36-3.7-3.4 0-2.28 1.7-3.18 6.48-3.4v-.46c0-1.14-.6-1.66-1.9-1.66zm-.18 7.08c.78 0 1.46-.28 2.08-.86v-2.5c-3.28.28-4.08.62-4.08 1.74 0 1 .78 1.62 2 1.62zm6.9-5.82c0-1.94 1.58-3.3 3.86-3.3 1.28 0 2.58.42 3.82 1.24l-1.16 1.8c-1.02-.72-1.9-1.08-2.66-1.08-.84 0-1.46.44-1.46 1.08 0 1.88 5.52.84 5.52 4.52 0 2.02-1.66 3.4-4.08 3.4-1.46 0-3-.5-4.36-1.44l1.2-1.78c1.16.84 2.22 1.26 3.2 1.26 1 0 1.64-.44 1.64-1.12 0-1.98-5.52-.96-5.52-4.58zm8.86-1.14V6.6h1.84V3.8l2.4-.48V6.6h2.8v1.88h-2.8v5.26c0 .94.42 1.38 1.3 1.38.4 0 .92-.1 1.38-.26l.36 1.84c-.92.3-1.74.46-2.46.46-1.92 0-2.98-1.06-2.98-3.02V8.48h-1.84z" fill="#3F3F3F"/><g fill="#0066ff"><path d="M7.03 16.09h17.818a9.84 9.84 0 0 0 .1-6.39c-.798-2.454-2.485-4.443-4.752-5.603a9.258 9.258 0 0 0-7.245-.535c-4.968 1.68-7.669 7.167-6.021 12.233.032.099.065.197.1.295m23.595 2.452H6.245c-.425 0-.818-.23-1.034-.601l-.071-.121a1.372 1.372 0 0 1-.064-.127c-.16-.367-.305-.746-.428-1.126-2.065-6.349 1.32-13.227 7.545-15.333a11.615 11.615 0 0 1 9.081.672c2.84 1.453 4.955 3.947 5.956 7.022.76 2.337.804 4.826.146 7.162h3.249c.664 0 1.202.55 1.202 1.226 0 .676-.538 1.226-1.202 1.226"/><path d="M17.141 12.893c0 .677-.538 1.225-1.202 1.225a1.214 1.214 0 0 1-1.202-1.225c0-.678.538-1.226 1.202-1.226.664 0 1.202.548 1.202 1.226"/><path d="M9.881 14.118c-.66 0-1.196-.541-1.202-1.215a7.56 7.56 0 0 1 .95-3.729 7.281 7.281 0 0 1 4.408-3.509 7.136 7.136 0 0 1 5.55.698 7.295 7.295 0 0 1 2.123 1.85c.412.53.325 1.3-.195 1.721a1.186 1.186 0 0 1-1.689-.198 4.907 4.907 0 0 0-1.424-1.24 4.792 4.792 0 0 0-3.724-.468 4.887 4.887 0 0 0-2.957 2.354 5.065 5.065 0 0 0-.638 2.5 1.215 1.215 0 0 1-1.192 1.236h-.01zM1.202 18.602C.54 18.602 0 18.052 0 17.376c0-.677.539-1.226 1.202-1.226h1.503c.663 0 1.202.55 1.202 1.226 0 .676-.539 1.226-1.202 1.226H1.202z"/></g><path d="M118.496 15.443H118V15h1.488v.443h-.496V17h-.496v-1.557zM119.97 15h.514l.294.83.103.327h.012l.104-.326.282-.831h.513v2h-.46v-.59c0-.052.002-.108.006-.17a17.151 17.151 0 0 1 .036-.378l.02-.167h-.011l-.156.468-.26.674h-.184l-.26-.674-.149-.468h-.012l.02.167a5.393 5.393 0 0 1 .037.378c.004.062.007.118.007.17V17h-.456v-2z" fill="#2C253C"/></g></svg></h1>
     67            <?php
    6868            settings_errors( "pinecast_settings_page" );
    6969
     
    9292
    9393        if ( empty( $podcasts ) ) {
    94             $podcasts = array(
     94            $podcasts = array(
    9595                Podcast::create( mt_rand( 10000000, 99999999 ), array() )
    96             );
    97         }
     96            );
     97        }
    9898
    9999        ?><div class="pinecast-feeds-wrap">
    100             <div class="pinecast-feeds"><?php
    101                 foreach ( $podcasts as $k => $podcast ) :
    102                    require 'views/podcast-row.php';
    103                 endforeach;
    104             ?></div><?php
    105 
    106             $podcast = Podcast::create( 9999, array() );
    107             ?><div class="pinecast-feed-template"><?php
    108                 require 'views/podcast-row.php';
    109             ?></div>
    110             <a href="javascript:void(0);" class="button button-secondary" id="pinecast-add-podcast"><?php _e( 'Add another podcast', 'pinecast' ); ?></a>
    111         </div><?php
     100                <div class="pinecast-feeds"><?php
     101                    foreach ( $podcasts as $k => $podcast ) :
     102                        require 'views/podcast-row.php';
     103                    endforeach;
     104                ?></div>
     105                <?php
     106                $podcast = Podcast::create( 9999, array() );
     107                ?>
     108                <div class="pinecast-feed-template"><?php require 'views/podcast-row.php'; ?></div>
     109                <a href="javascript:void(0);" class="button button-secondary" id="pinecast-add-podcast"><?php _e( 'Add another podcast', 'pinecast' ); ?></a>
     110        </div><?php
    112111    }
    113112
  • pinecast-wp-sync/trunk/includes/admin/views/podcast-row.php

    r2264272 r2517018  
    99?><div class="pinecast-feed open" data-podcast-id="<?php echo absint( $podcast->get_id() ); ?>">
    1010    <div class="pinecast-feed-header">
    11         <div class="title"><?php
     11        <h2 class="title"><?php
    1212            if ( ! empty( $podcast->get_name() ) ) :
    1313                echo esc_html( $podcast->get_name() );
     
    1515                ?><span class="placeholder"><?php _e( 'Add a new podcast', 'pinecast' ); ?></span><?php
    1616            endif;
    17         ?></div>
    18         <div class="delete"><?php _e( 'Delete', 'pinecast' ); ?></div>
     17        ?></h2>
     18        <button type="button" class="delete"><?php _e( 'Delete', 'pinecast' ); ?></button>
    1919        <div class="handlediv toggle-indicator" title="<?php _e( 'Click to toggle' ); ?>" aria-expanded="true"></div>
    2020    </div>
     
    2424            <div class="label"><?php
    2525                _e( 'Podcast name', 'pinecast' );
    26                 ?><p class="description"><?php _e( 'The name of your podcast as it appears in WordPress settings', 'pinecast' ); ?></p>
     26                ?><p class="description"><?php _e( 'The name of your podcast as it appears here, for your reference', 'pinecast' ); ?></p>
    2727            </div>
    2828            <div class="field">
     
    3838
    3939        <div class="row">
    40             <div class="label"><?php _e( 'Pinecast feed URL', 'pinecast' ); ?></div>
     40            <div class="label"><?php _e( 'Feed URL', 'pinecast' ); ?></div>
    4141            <div class="field">
    4242                <input
     
    4545                    value="<?php echo esc_url( $podcast->get_feed_url() ); ?>"
    4646                    <?php if ($podcast->get_feed_url()) {echo 'readonly';} ?>
    47                     pattern="https?://.+"
     47                    pattern="https://.+"
     48                    placeholder="https://pinecast.com/feed/…"
    4849                    class="otherwise-required"
    4950                    <?php if ($podcast->get_feed_url()) {echo 'required';} ?>
     
    5859            </div>
    5960            <div class="field"><?php
    60                 $category_ids = $podcast->get_category_ids();
     61                $category_ids = $podcast->get_category_ids();
    6162                wp_dropdown_categories( array(
    6263                    'show_option_none' => __( 'Do not assign a category', 'pinecast' ),
     
    6970
    7071        <div class="row">
    71             <div class="label"><?php
    72                 _e( 'Featured image', 'pinecast' );
    73                 ?><p class="description"><?php _e( 'Use the episode artwork as featured image', 'pinecast' ); ?></p>
     72            <div class="label">
     73                <?php _e( 'Featured image', 'pinecast' ); ?>
     74                <p class="description"><?php _e( 'Copy unique episode artwork to WordPress', 'pinecast' ); ?></p>
    7475            </div>
    7576            <div class="field">
    76                 <input name="pinecast_feeds[<?php echo absint( $podcast->get_id() ); ?>][featured_image]" type="checkbox" value="1" <?php checked( $podcast->use_featured_image() ); ?>>
    77             </div>
     77                <input name="pinecast_feeds[<?php echo absint( $podcast->get_id() ); ?>][featured_image]" type="checkbox" value="1" <?php checked( $podcast->use_featured_image() ); ?>>
     78                <label for="pinecast_feeds[<?php echo absint( $podcast->get_id() ); ?>][featured_image]">
     79                    <?php _e( 'Use the episode artwork as featured image', 'pinecast' ); ?>
     80                </label>
     81                <br>
     82                <p class="description">
     83                    <?php _e( 'Since artwork needs to be copied to your server, this option may increase sync times. For shows with many episodes and large artwork files, it may take multiple sync attempts to finish importing artwork.', 'pinecast' ); ?>
     84                </p>
     85            </div>
    7886        </div>
    7987
    8088        <?php if ($podcast->can_sync()) { ?>
    81         <div class="row actions">
    82             <div class="label"><?php _e( 'Actions', 'pinecast' ); ?></div>
    83             <div class="field">
    84                 <a href="javascript:void(0);" <?php disabled( ! $podcast->can_sync() ) ?> class="pinecast-sync-now button button-secondary"><i class="dashicons dashicons-update"></i> <?php _e( 'Refresh feed', 'pinecast' ); ?></a>
    85                 <span class="spinner sync-spinner"></span>
    86                 <br/><span class="description"><?php echo sprintf( __( 'Last updated: %s', 'pinecast' ), '<span class="last-updated">' . ($podcast->get_last_updated() ?? 'Never') ) . '</span>'; ?></span><?php
    87             ?></div>
    88         </div>
     89            <div class="row actions">
     90                <div class="label"><?php _e( 'Actions', 'pinecast' ); ?></div>
     91                <div class="field">
     92                    <a href="javascript:void(0);" <?php disabled( ! $podcast->can_sync() ) ?> class="pinecast-sync-now button button-secondary">
     93                        <i class="dashicons dashicons-update"></i> <?php _e( 'Refresh feed', 'pinecast' ); ?>
     94                    </a>
     95                    <span class="spinner sync-spinner"></span>
     96                    <br>
     97                    <span class="description"><?php echo sprintf( __( 'Last updated: %s', 'pinecast' ), '<span class="last-updated">' . ($podcast->get_last_updated() ?? 'Never') ) . '</span>'; ?></span>
     98                </div>
     99            </div>
    89100        <?php } ?>
    90101
  • pinecast-wp-sync/trunk/includes/ajax-functions.php

    r2310548 r2517018  
    1717
    1818    if ( $podcast = get_podcast( wp_unslash($_POST['podcast']) ) ) {
    19         $result = $podcast->sync_episodes();
    20         if ($result) {
    21             wp_send_json( array(
    22                 'success' => false,
    23                 'error' => 'could not sync',
    24                 'result' => $result,
    25                 'feed_url' => $podcast->get_feed_url(),
    26             ) );
    27             return;
    28         }
     19        $podcast->sync_episodes();
     20        $podcast->sync_artwork();
    2921        $podcast
    3022            ->set_last_updated()
  • pinecast-wp-sync/trunk/includes/class-podcast.php

    r2473390 r2517018  
    2323    /** @var string Last time the podcast was synced. */
    2424    private $last_updated = null;
     25
     26    /** @var string Synced content of the feed. */
     27    private $feed_data_cache = null;
    2528
    2629
     
    185188     */
    186189    public function get_feed() {
    187         $response = wp_remote_get(
    188             $this->feed_url,
    189             ['user-agent' => 'WordPress; Pinecast Sync Plugin']
    190         );
    191         $body     = wp_remote_retrieve_body( $response );
    192         $body     = json_decode( $body );
     190        if ($this->feed_data_cache) {
     191            $body = $this->feed_data_cache;
     192        } else {
     193            $response = wp_remote_get(
     194                $this->feed_url,
     195                ['user-agent' => 'WordPress; Pinecast Sync Plugin']
     196            );
     197            $body = wp_remote_retrieve_body( $response );
     198        }
     199        $body = json_decode( $body );
    193200
    194201        return $body;
     
    284291     */
    285292    public function can_sync() {
    286         return ! empty( $this->get_feed_url() );
     293        return !empty( $this->get_feed_url() );
    287294    }
    288295
     
    292299     *
    293300     * Synchronize the podcast episodes, create new posts if they don't exist yet.
    294      *
    295      * @return string|bool Returns an error or false
    296301     */
    297302    public function sync_episodes() {
     
    299304
    300305        if ( empty( $feed->items ) ) {
    301             return 'Feed was empty';
     306            return;
    302307        }
    303308
     
    314319            }
    315320        }
    316 
    317         return false;
     321    }
     322
     323    /**
     324     * Synchronize episode artwork.
     325     */
     326    public function sync_artwork() {
     327        $feed = $this->get_feed();
     328
     329        if ( empty( $feed->items ) ) {
     330            return;
     331        }
     332
     333        global $wpdb;
     334        $results = $wpdb->get_results( "SELECT meta_value, post_id FROM {$wpdb->prefix}postmeta WHERE meta_key = '_pinecast_id'", OBJECT_K );
     335        $existing_episode_ids = array_keys( $results );
     336
     337        $start_time = time();
     338        $created_posts = array();
     339        foreach ( $feed->items as $episode ) {
     340            if ( !in_array( $episode->id, $existing_episode_ids ) ) {
     341                continue;
     342            }
     343            if ($this->use_featured_image()){
     344                $this->update_episode_artwork( $episode, $results[$episode->id]->post_id );
     345            } else {
     346                $this->clear_episode_artwork( $results[$episode->id]->post_id );
     347            }
     348
     349            // Short-circuit if this is taking way too long.
     350            $now_time = time();
     351            if ($now_time - $start_time > 25) {
     352                break;
     353            }
     354        }
    318355    }
    319356
     
    361398        }
    362399
    363         if ( $this->use_featured_image() && !empty( $data->image ) ) {
    364             if ( $attachment_id = $this->import_episode_image( $data->image, $post_id, true ) ) {
    365                 set_post_thumbnail( $post_id, $attachment_id );
    366             }
    367         }
    368 
    369400        do_action( 'pinecast/create_episode', $post_id, $data );
    370401
     
    382413    private function update_episode_post( $data, $id ) {
    383414        $post_data = $this->get_post_data($data);
    384         $post_data['ID'] = $id;
    385         if (has_excerpt($id)) {
    386             $post_data['post_excerpt'] = get_the_excerpt($id);
    387         }
     415        $post_data['ID'] = $id;
     416        if (has_excerpt($id)) {
     417            $post_data['post_excerpt'] = get_the_excerpt($id);
     418        }
    388419        $post_id = wp_insert_post( $post_data );
    389420
     
    392423        }
    393424
    394         if ( $this->use_featured_image() ) {
    395             if (!empty($data->image) && $attachment_id = $this->import_episode_image( $data->image, $post_id ) ) {
    396                 set_post_thumbnail( $post_id, $attachment_id );
    397             }
    398         } else {
    399             if (has_post_thumbnail($post_id)) {
    400                 delete_post_thumbnail($post_id);
    401                 delete_post_meta($post_id, '_pinecast_image');
    402             }
    403         }
    404 
    405425        do_action( 'pinecast/update_episode', $post_id, $data );
    406426
     
    410430
    411431    /**
    412      * Import episode image.
    413      *
    414      * Import the featured image to the post of a episode.
    415      *
    416      * @param string $image_url Image URL to import.
    417      * @param int    $post_id ID of the post related to the episode.
    418      * @return bool|int Attachment ID on success, false otherwise.
    419      */
    420     private function import_episode_image( $image_url, $post_id, $override = false ) {
     432     * Update episode's artwork.
     433     *
     434     * @param array $data Data provided through the RSS feed.
     435     * @param int $post_id The ID of the existing post
     436     */
     437    private function update_episode_artwork( $data, $post_id ) {
     438        if (empty($data->image)) {
     439            return;
     440        }
     441        $image_url = $data->image;
     442        $original_image_url = $image_url;
     443
    421444        require_once ABSPATH . 'wp-includes/post.php';
    422445        require_once ABSPATH . 'wp-admin/includes/image.php';
     
    424447        require_once ABSPATH . 'wp-admin/includes/media.php';
    425448
    426         if (!$override) {
    427             $existing_image = get_post_meta($post_id, '_pinecast_image', true);
    428             if ($existing_image === $image_url) {
    429                 // Don't update if it hasn't changed.
    430                 return false;
    431             } elseif ($existing_image) {
    432                 // If there was an existing image that's not the current image, delete it.
    433                 delete_post_thumbnail($post_id);
    434                 delete_post_meta($post_id, '_pinecast_image');
    435             } elseif (has_post_thumbnail($post_id)) {
    436                 // If there was an existing image that's not from Pinecast,
    437                 // don't overwrite it.
    438                 return false;
    439             }
     449        $existing_image = get_post_meta($post_id, '_pinecast_image', true);
     450        if ($existing_image === $image_url) {
     451            // Don't update if it hasn't changed.
     452            return;
     453        } elseif ($existing_image) {
     454            // If there was an existing image that's not the current image, delete it.
     455            delete_post_thumbnail($post_id);
     456            delete_post_meta($post_id, '_pinecast_image');
     457        } elseif (has_post_thumbnail($post_id)) {
     458            // If there was an existing image that's not from Pinecast,
     459            // don't overwrite it.
     460            return;
     461        }
     462
     463        // Rewrite the image URL to use the cropped version from the CDN, if it's
     464        // using the Pinecast CDN.
     465        if (strpos($image_url, 'https://storage.pinecast.net/podcasts/') === 0) {
     466            $image_url = str_replace(
     467                'https://storage.pinecast.net/podcasts/',
     468                'https://storage.pinecast.net/cdn-cgi/image/w=1280,h=1280,fit=scale-down,anim=false,onerror=redirect,metadata=none/podcasts/',
     469                $image_url
     470            );
    440471        }
    441472
    442473        // Download file to temp dir
    443         $temp_file = download_url( $image_url, $timeout_seconds = 5 );
    444 
    445         if ( ! is_wp_error( $temp_file ) ) {
    446             $file = array(
    447                 'name'     => basename( $image_url ),
    448                 'type'     => mime_content_type( $temp_file ),
    449                 'tmp_name' => $temp_file,
    450                 'error'    => 0,
    451                 'size'     => filesize( $temp_file ),
    452             );
    453 
    454             // Move temporary file to uploads directory
    455             $attachment_id = media_handle_sideload( $file, $post_id );
    456 
    457             update_post_meta($post_id, '_pinecast_image', $image_url);
    458 
    459             return $attachment_id;
    460         }
    461 
    462         return false;
     474        $temp_file = download_url( $image_url, $timeout_seconds = 10 );
     475        if ( is_wp_error( $temp_file ) ) {
     476            return;
     477        }
     478
     479        $file = array(
     480            'name'     => basename( $image_url ),
     481            'type'     => mime_content_type( $temp_file ),
     482            'tmp_name' => $temp_file,
     483            'error'    => 0,
     484            'size'     => filesize( $temp_file ),
     485        );
     486
     487        // Move temporary file to uploads directory
     488        $attachment_id = media_handle_sideload( $file, $post_id );
     489
     490        update_post_meta($post_id, '_pinecast_image', $original_image_url);
     491        set_post_thumbnail( $post_id, $attachment_id );
     492        do_action( 'pinecast/update_episode_artwork', $post_id );
     493    }
     494
     495    /**
     496     * Clear episode's artwork.
     497     *
     498     * @param int $post_id The ID of the existing post
     499     */
     500    private function clear_episode_artwork( $post_id ) {
     501        // Delete the post image if there's a thumbnail and it's from Pinecast.
     502        if (has_post_thumbnail($post_id) && get_post_meta($post_id, '_pinecast_image', true)) {
     503            delete_post_thumbnail($post_id);
     504            delete_post_meta($post_id, '_pinecast_image');
     505            do_action( 'pinecast/clear_episode_artwork', $post_id);
     506        }
    463507    }
    464508}
  • pinecast-wp-sync/trunk/includes/cron-functions.php

    r2339437 r2517018  
    2323 */
    2424function check_podcast_sync() {
     25    $start_time = time();
     26
    2527    $podcasts = get_podcasts();
    2628
     
    3133    });
    3234
     35    // First, sync episodes. This creates and updates posts with content and metadata.
    3336    array_walk( $podcasts, function( $podcast ) {
    3437        /** @var Podcast $podcast */
     
    3841            ->update();
    3942    } );
     43    // After, we walk the podcasts again and sync artwork. This done separately, in case
     44    // artwork download causes timeouts.
     45    array_walk( $podcasts, function( $podcast ) use ($start_time) {
     46        /** @var Podcast $podcast */
     47
     48        // If we're taking too long, abort artwork sync early.
     49        $now_time = time();
     50        if ($now_time - $start_time > 25) {
     51            return;
     52        }
     53
     54        $podcast->sync_artwork();
     55
     56        $podcast->set_last_updated()
     57            ->update();
     58
     59    } );
    4060}
    4161add_action( 'pinecast/feed_sync', '\Pinecast\check_podcast_sync' );
  • pinecast-wp-sync/trunk/package-lock.json

    r2473390 r2517018  
    11{
    22  "name": "pinecast",
    3   "version": "1.0.14",
     3  "version": "1.1.0",
    44  "lockfileVersion": 1,
    55  "requires": true,
  • pinecast-wp-sync/trunk/package.json

    r2473390 r2517018  
    11{
    22  "name": "pinecast",
    3   "version": "1.0.14",
     3  "version": "1.1.0",
    44  "description": "",
    55  "main": "gulpfile.js",
  • pinecast-wp-sync/trunk/pinecast.php

    r2473390 r2517018  
    88
    99        /** @var string Plugin version */
    10         public $version = '1.0.14';
     10        public $version = '1.1.0';
    1111
    1212        /** @var string Main plugin file */
  • pinecast-wp-sync/trunk/plugin.php

    r2473390 r2517018  
    44 * Plugin URI:      https://help.pinecast.com/articles/3072843-pinecast-wordpress-sync-plugin
    55 * Description:     Sync your Pinecast podcast episodes from Pinecast to WordPress
    6  * Version:         1.0.14
     6 * Version:         1.1.0
    77 * Author:          Pinecast
    88 * Author URI:      https://pinecast.com
  • pinecast-wp-sync/trunk/readme.txt

    r2473390 r2517018  
    33Tags: pinecast, sync, jsonfeed, podcast
    44Requires at least: 5.2
    5 Tested up to: 5.6
    6 Stable tag: 1.0.14
     5Tested up to: 5.7
     6Stable tag: 1.1.0
    77Requires PHP: 7.0
    88License: GPLv2 or later
     
    1515This plugin allows you to sync your Pinecast podcast (or any JSONFeed-compatible podcast) with your WordPress blog.
    1616
    17 Please see Pinecast's [support website](https://help.pinecast.com/en/articles/3072843-pinecast-wordpress-sync-plugin) for more information.
     17Please see Pinecast's [support website](https://pinecast.support/en/articles/3072843-pinecast-wordpress-sync-plugin) for more information.
    1818
    1919After installing, visit Settings > Pinecast to add feeds. Add your Pinecast RSS feed URL (found on your podcast dashboard), along with the podcast's name (for your reference), categories that you wish to be applied to each episode's post, and whether you'd like to include episode artwork in the posts. Save changes.
     
    2828
    2929== Changelog ==
     30
     31= 1.1.0 =
     32* New two-phase sync algorithm prioritizes episode creation over artwork download, preventing sync timeout errors from blocking episode creation
     33* Very large episode artwork is resized/re-encoded to save space and improve sync times.
     34* Accessibility improvements on the settings page
     35* Better wording on settings page options
    3036
    3137= 1.0.13 =
Note: See TracChangeset for help on using the changeset viewer.