You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

4 lines
74 KiB
JavaScript

(()=>{var e={6774:e=>{e.exports=function(e,t,r,n){var o=r?r.call(n,e,t):void 0;if(void 0!==o)return!!o;if(e===t)return!0;if("object"!=typeof e||!e||"object"!=typeof t||!t)return!1;var i=Object.keys(e),a=Object.keys(t);if(i.length!==a.length)return!1;for(var s=Object.prototype.hasOwnProperty.bind(t),c=0;c<i.length;c++){var l=i[c];if(!s(l))return!1;var u=e[l],f=t[l];if(!1===(o=r?r.call(n,u,f,l):void 0)||void 0===o&&u!==f)return!1}return!0}},9917:(e,t)=>{var r;function Tokenizer(e,t){var r=[],n=0;function o(e){return r.push(e),t}function i(){return r[n++]}return{tokenize:function(t){return t.replace(e,o)},detokenize:function(e){return e.replace(new RegExp("("+t+")","g"),i)}}}r=new function CSSJanus(){var e="`TMP`",t="`COMMENT`",r="[^\\u0020-\\u007e]",n="(?:[0-9]*\\.[0-9]+|[0-9]+)",o="direction\\s*:\\s*",i="['\"]?\\s*",a="(^|[^a-zA-Z])",s="\\/\\*\\!?\\s*@noflip\\s*\\*\\/",c="(?:(?:(?:\\\\[0-9a-f]{1,6})(?:\\r\\n|\\s)?)|\\\\[^\\r\\n\\f0-9a-f])",l="(?:[_a-z0-9-]|"+r+"|"+c+")",u=n+"(?:\\s*(?:em|ex|px|cm|mm|in|pt|pc|deg|rad|grad|ms|s|hz|khz|%)|"+("-?"+("(?:[_a-z]|"+r+"|"+c+")")+l+"*")+")?",f="((?:-?"+u+")|(?:inherit|auto))",p="(#?"+l+"+|(?:rgba?|hsla?)\\([ \\d.,%-]+\\))",d="(?:[!#$%&*-~]|"+r+"|"+c+")*?",h="(?![a-zA-Z])",g="(?!("+l+"|\\r?\\n|\\s|#|\\:|\\.|\\,|\\+|>|~|\\(|\\)|\\[|\\]|=|\\*=|~=|\\^=|'[^']*'|\"[^\"]*\"|"+t+")*?{)",m="(?!"+d+i+"\\))",y="(?="+d+i+"\\))",b="(\\s*(?:!important\\s*)?[;}])",v=/`TMP`/g,w=new RegExp("\\/\\*[^*]*\\*+([^\\/*][^*]*\\*+)*\\/","gi"),_=new RegExp("("+s+g+"[^;}]+;?)","gi"),x=new RegExp("("+s+"[^\\}]*?})","gi"),S=new RegExp("("+o+")ltr","gi"),k=new RegExp("("+o+")rtl","gi"),E=new RegExp(a+"(left)"+h+m+g,"gi"),I=new RegExp(a+"(right)"+h+m+g,"gi"),P=new RegExp(a+"(left)"+y,"gi"),C=new RegExp(a+"(right)"+y,"gi"),O=new RegExp(a+"(ltr)"+y,"gi"),A=new RegExp(a+"(rtl)"+y,"gi"),$=new RegExp(a+"([ns]?)e-resize","gi"),j=new RegExp(a+"([ns]?)w-resize","gi"),R=new RegExp("((?:margin|padding|border-width)\\s*:\\s*)"+f+"(\\s+)"+f+"(\\s+)"+f+"(\\s+)"+f+b,"gi"),T=new RegExp("((?:-color|border-style)\\s*:\\s*)"+p+"(\\s+)"+p+"(\\s+)"+p+"(\\s+)"+p+b,"gi"),z=new RegExp("(background(?:-position)?\\s*:\\s*(?:[^:;}\\s]+\\s+)*?)("+u+")","gi"),N=new RegExp("(background-position-x\\s*:\\s*)(-?"+n+"%)","gi"),U=new RegExp("(border-radius\\s*:\\s*)"+f+"(?:(?:\\s+"+f+")(?:\\s+"+f+")?(?:\\s+"+f+")?)?(?:(?:(?:\\s*\\/\\s*)"+f+")(?:\\s+"+f+")?(?:\\s+"+f+")?(?:\\s+"+f+")?)?"+b,"gi"),F=new RegExp("(box-shadow\\s*:\\s*(?:inset\\s*)?)"+f,"gi"),L=new RegExp("(text-shadow\\s*:\\s*)"+f+"(\\s*)"+p,"gi"),M=new RegExp("(text-shadow\\s*:\\s*)"+p+"(\\s*)"+f,"gi"),D=new RegExp("(text-shadow\\s*:\\s*)"+f,"gi"),W=new RegExp("(transform\\s*:[^;}]*)(translateX\\s*\\(\\s*)"+f+"(\\s*\\))","gi"),G=new RegExp("(transform\\s*:[^;}]*)(translate\\s*\\(\\s*)"+f+"((?:\\s*,\\s*"+f+"){0,2}\\s*\\))","gi");function q(e,t,r){var n,o;return"%"===r.slice(-1)&&(-1!==(n=r.indexOf("."))?(o=r.length-n-2,r=(r=100-parseFloat(r)).toFixed(o)+"%"):r=100-parseFloat(r)+"%"),t+r}function H(e){switch(e.length){case 4:e=[e[1],e[0],e[3],e[2]];break;case 3:e=[e[1],e[0],e[1],e[2]];break;case 2:e=[e[1],e[0]];break;case 1:e=[e[0]]}return e.join(" ")}function B(e,t){var r=[].slice.call(arguments),n=r.slice(2,6).filter((function(e){return e})),o=r.slice(6,10).filter((function(e){return e})),i=r[10]||"";return t+(o.length?H(n)+" / "+H(o):H(n))+i}function Y(e){return 0===parseFloat(e)?e:"-"===e[0]?e.slice(1):"-"+e}function V(e,t,r){return t+Y(r)}function X(e,t,r,n,o){return t+r+Y(n)+o}function K(e,t,r,n,o){return t+r+n+Y(o)}return{transform:function(r,n){var o=new Tokenizer(_,"`NOFLIP_SINGLE`"),i=new Tokenizer(x,"`NOFLIP_CLASS`"),a=new Tokenizer(w,t);return r=a.tokenize(i.tokenize(o.tokenize(r.replace("`","%60")))),n.transformDirInUrl&&(r=r.replace(O,"$1"+e).replace(A,"$1ltr").replace(v,"rtl")),n.transformEdgeInUrl&&(r=r.replace(P,"$1"+e).replace(C,"$1left").replace(v,"right")),r=r.replace(S,"$1"+e).replace(k,"$1ltr").replace(v,"rtl").replace(E,"$1"+e).replace(I,"$1left").replace(v,"right").replace($,"$1$2"+e).replace(j,"$1$2e-resize").replace(v,"w-resize").replace(U,B).replace(F,V).rep
(0,Lr._x)("1","Step number","web-stories")),t().createElement(qr,{$secondary:!0},n)))},cn=cr.div.withConfig({displayName:"step2__Wrapper",componentId:"sc-1l994u2-0"})(["display:none;margin-left:20px;justify-content:center;@media ","{display:flex;}"],(e=>{let{theme:t}=e;return t.breakpoint.tabletLarge})),ln=cr.div.withConfig({displayName:"step2__ParagraphWrapper",componentId:"sc-1l994u2-1"})(["align-self:flex-start;margin:20px 0 0 -50px;min-width:100px;"]);const un=function Step2(){const{dashboardURL:e}=Wr(),r=(0,I.useCallback)((e=>{E(e,"open_dashboard")}),[]),n=(0,I.createInterpolateElement)((0,Lr.__)("Head to the <a>Dashboard</a>","web-stories"),{a:t().createElement(Br,{href:e,onClick:r})});return t().createElement(cn,null,t().createElement(Br,{href:e,onClick:r},t().createElement(nn,{name:"dashboard.png",name2x:"dashboard-2x.png",width:420,height:246})),t().createElement(ln,null,t().createElement(en,null,/* translators: Number of the step displayed in plugin activation message. */
(0,Lr._x)("2","Step number","web-stories")),t().createElement(qr,{$secondary:!0},n)))},fn=cr.div.withConfig({displayName:"step3__Wrapper",componentId:"sc-2yps0y-0"})(["display:none;margin-left:30px;justify-content:center;@media ","{display:flex;}"],(e=>{let{theme:t}=e;return t.breakpoint.desktop})),pn=cr.div.withConfig({displayName:"step3__ParagraphWrapper",componentId:"sc-2yps0y-1"})(["align-self:flex-start;margin:20px 0 0 -50px;"]);const dn=function Step3(){const{newStoryURL:e}=Wr(),r=(0,I.useCallback)((e=>{E(e,"open_story_editor")}),[]),n=(0,I.createInterpolateElement)((0,Lr.__)("Jump into the <a>Editor</a>","web-stories"),{a:t().createElement(Br,{href:e,onClick:r})});return t().createElement(fn,null,t().createElement(Br,{href:e,onClick:r},t().createElement(nn,{name:"editor.png",name2x:"editor-2x.png",width:430,height:251})),t().createElement(pn,null,t().createElement(en,null,/* translators: Number of the step displayed in plugin activation message. */
(0,Lr._x)("3","Step number","web-stories")),t().createElement(qr,null,n)))},hn=cr.div.withConfig({displayName:"messageContent__Wrapper",componentId:"sc-1kvy6cu-0"})(["font-family:",";font-size:",";line-height:",";font-weight:",";color:",";background:",";box-sizing:border-box;display:flex;overflow:hidden;padding:0 30px 0 45px;justify-content:center;@media ","{max-height:245px;}@media ","{justify-content:space-around;}"],(e=>{let{theme:t}=e;return t.fonts.body.family}),(e=>{let{theme:t}=e;return t.fonts.body.size}),(e=>{let{theme:t}=e;return t.fonts.body.lineHeight}),(e=>{let{theme:t}=e;return t.fonts.body.fontWeight}),(e=>{let{theme:t}=e;return t.colors.primary}),(e=>{let{theme:t}=e;return`linear-gradient(\n 115.54deg,\n ${Fr(t.colors.bg.start,.2)} 9.27%,\n ${Fr(t.colors.bg.end,.2)} 47.82%,\n ${Fr(t.colors.bg.end,0)} 66.64%\n ),\n linear-gradient(\n 158.59deg,\n ${Fr(t.colors.bg.start,.3)} 13.24%,\n ${Fr(t.colors.bg.end,.3)} 86.01%\n ),\n linear-gradient(\n 115.54deg,\n ${Fr(t.colors.bg.start,.2)} 9.27%,\n ${Fr(t.colors.bg.end,.2)} 47.82%,\n ${Fr(t.colors.bg.end,0)} 66.64%\n ),\n linear-gradient(70.23deg, #010218 -28.03%, #1b0418 95.56%)`}),(e=>{let{theme:t}=e;return t.breakpoint.tabletSmall}),(e=>{let{theme:t}=e;return t.breakpoint.tabletLarge}));const gn=function MessageContent(){return t().createElement(hn,null,t().createElement(Jr,null),t().createElement(Zr,null),t().createElement(sn,null),t().createElement(un,null),t().createElement(dn,null))};Object.defineProperty(hr,"name",{value:"stylisRTLPlugin"});const mn=function App(e){let{config:r}=e;const{isRTL:n}=r;return t().createElement(Me,{stylisPlugins:n?[hr]:[],shouldForwardProp:O},t().createElement(Xe,{theme:mr},t().createElement(Dr,{config:r},t().createElement(gr,null),t().createElement(gn,null))))};__webpack_require__.p=window.webStoriesActivationSettings.publicPath;const yn=()=>{const{id:e,config:r,flags:n}=window.webStoriesActivationSettings;((e,r,n)=>{const o=document.getElementById(e);if(!o)return;k("Plugin Activation"),(0,I.createRoot)(o).render(t().createElement(FlagsProvider,{features:n},t().createElement(I.StrictMode,null,t().createElement(mn,{config:r}))))})(e,r,n)};"loading"===document.readyState?document.addEventListener("DOMContentLoaded",yn):yn()})()})();