From a87ec3a06077a24e91e0c727e56b7a77dde7141e Mon Sep 17 00:00:00 2001 From: Zixaphir Date: Wed, 8 May 2013 05:35:52 -0700 Subject: [PATCH] More or less improve the mascot section code. --- builds/appchan-x.js | 71 +++++++------- builds/appchan-x.user.js | 71 +++++++------- builds/crx/script.js | 71 +++++++------- src/General/Settings.coffee | 100 +++++++++----------- src/General/css/layout.css | 10 +- src/General/html/Settings/Batch-Mascot.html | 11 +++ src/General/html/Settings/Mascot.html | 3 + src/Theming/Mascots.coffee | 4 +- 8 files changed, 172 insertions(+), 169 deletions(-) create mode 100644 src/General/html/Settings/Batch-Mascot.html create mode 100644 src/General/html/Settings/Mascot.html diff --git a/builds/appchan-x.js b/builds/appchan-x.js index 72afffb6f..6810804a6 100644 --- a/builds/appchan-x.js +++ b/builds/appchan-x.js @@ -10522,7 +10522,7 @@ }, categories: ['Anime', 'Ponies', 'Questionable', 'Silhouette', 'Western'], dialog: function(key) { - var dialog, div, fileInput, input, item, layout, name, option, optionHTML, setting, value, _i, _len, _ref; + var dialog, div, fileInput, input, item, layout, name, nodes, option, optionHTML, setting, value, _i, _len, _ref; Conf['editMode'] = 'mascot'; if (Mascots[key]) { @@ -10549,6 +10549,7 @@ className: "reply dialog", innerHTML: "

PROTIP: Shift-Click the Mascot Image field to upload your own images!
This may have some caveats.
Save Mascot
Close
" }); + nodes = []; for (name in layout) { item = layout[name]; switch (item[2]) { @@ -10636,8 +10637,9 @@ return Style.addStyle(); }); } - $.add($("#mascotcontent", dialog), div); + nodes.push(div); } + $.add($("#mascotcontent", dialog), nodes); $.on($('#save > a', dialog), 'click', function() { return MascotTools.save(editMascot); }); @@ -11152,7 +11154,7 @@ "slideout": "#qrtab input,#qrtab .rice { display: none;}#qr { top: auto !important; bottom: " + Style.pfOffset + "em !important; " + Style.sidebarLocation[0] + ": 0 !important; " + Style.sidebarLocation[1] + ": auto !important; " + agent + "transform: translateX(" + xOffset + "93%);}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transform: translate(0);}", "tabbed slideout": "#qr { top: auto !important; bottom: " + Style.pfOffset + "em !important; " + Style.sidebarLocation[0] + ": 0 !important; " + Style.sidebarLocation[1] + ": auto !important; " + agent + "transform: translateX(" + xOffset + "100%);}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transform: translateX(0);}#qrtab { " + agent + "transform: rotate(" + (Style.sidebarLocation[0] === "left" ? "" : "-") + "90deg); " + agent + "transform-origin: bottom " + Style.sidebarLocation[0] + "; position: absolute; top: 0; " + Style.sidebarLocation[0] + ": 100%; width: 110px; text-align: center; border-width: 1px 1px 0 1px; cursor: default;}#qr:hover #qrtab,#qr.has-focus #qrtab,#qr.dump #qrtab { opacity: 0; " + Style.sidebarLocation[0] + ": " + (252 + Style.sidebarOffset.W) + "px;}#qrtab input,#qrtab .close,#qrtab .rice,#qrtab span { display: none;}", "transparent fade": "#qr { overflow: visible; top: auto !important; bottom: " + Style.pfOffset + "em !important; " + Style.sidebarLocation[0] + ": 2px !important; " + Style.sidebarLocation[1] + ": auto !important; opacity: 0.2; " + agent + "transition: opacity .3s ease-in-out 1s;}#qr:hover,#qr.has-focus,#qr.dump { opacity: 1; " + agent + "transition: opacity .3s linear;}" - }[_conf['Post Form Style']] || "") + "\n\n" + (_conf['Post Form Style'] !== 'tabbed slideout' ? (!(_conf['Post Form Style'] === 'float' || _conf['Show Post Form Header']) ? "#qrtab { display: none; }" : _conf['Post Form Style'] !== 'slideout' ? ".autohide:not(:hover):not(.has-focus) > form { display: none !important; }" : "") + "#qrtab { margin-bottom: 1px; }" : "") + "\n\n" + (_conf['Post Form Style'] !== 'float' && _conf["Post Form Slideout Transitions"] ? "#qr { " + agent + "transition: " + agent + "transform .3s ease-in-out 1s;}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transition: " + agent + "transform .3s linear;}#qrtab { " + agent + "transition: opacity .3s ease-in-out 1s;}#qr:hover #qrtab { " + agent + "transition: opacity .3s linear;}" : "") + "\n\n#qr .close {\n float: right;\n padding: 0 3px;\n}\n#qr .warning {\n min-height: 1.6em;\n vertical-align: middle;\n padding: 0 1px;\n border-width: 1px;\n border-style: solid;\n}\n.persona {\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-button {\n width: 10%;\n margin: 0;\n}\n\n" + (_conf['Compact Post Form Inputs'] ? ".persona input.field { width: 29.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 14.8em; min-height: 9em;}#qr.has-captcha textarea.field { height: 9em;}" : ".persona input.field { width: 100%;}.persona input.field[name='name'] { width: 89.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 11.6em; min-height: 6em;}#qr.has-captcha textarea.field { height: 6em;}") + "\n\n" + (_conf["Tripcode Hider"] ? ".tripped:not(:hover):not(:focus) { opacity: 0;}" : "") + "\n\n#qr textarea {\n resize: " + _conf['Textarea Resize'] + ";\n}\n.captcha-img {\n margin: 1px 0 0;\n text-align: center;\n line-height: 0;\n}\n.captcha-img img {\n width: 100%;\n height: 4em;\n width: 246px;\n}\n.captcha-input {\n width: 100%;\n margin: 1px 0 0;\n}\n.field,\n.selectrice,\nbutton,\ninput:not([type=radio]) {\n " + Style.sizing + ": border-box;\n font-size: " + (parseInt(_conf['Font Size'], 10)) + "px;\n height: 1.6em;\n margin: 1px 0 0;\n vertical-align: bottom;\n padding: 0 1px;\n}\n.selectrice {\n padding-right: 1.6em;\n}\n#qr textarea {\n min-width: 100%;\n}\n#qr [type='submit'] {\n width: 25%;\n}\n[type='file'] {\n position: absolute;\n opacity: 0;\n z-index: -1;\n}\n#showQR {\n display: " + (_conf["Hide Show Post Form"] ? "none" : "block") + ";\n z-index: 4;\n " + Style.sidebarLocation[0] + ": 2px;\n width: " + width + "px;\n background-color: transparent;\n text-align: center;\n position: fixed;\n top: auto;\n}\n/* Fake File Input */\n#qr-filename,\n.has-file #qr-no-file {\n display: none;\n}\n#qr-no-file,\n.has-file #qr-filename {\n display: block;\n}\n#qr-filename-container {\n " + Style.sizing + ": border-box;\n display: inline-block;\n position: relative;\n width: 100px;\n min-width: 74.6%;\n max-width: 74.6%;\n margin-right: 0.4%;\n overflow: hidden;\n padding: 2px 1px 0;\n}\n#qr-filerm {\n position: absolute;\n right: 3px;\n top: 2px;\n z-index: 2;\n}\n/* Thread Select / Spoiler Label */\n#qr-thread-select {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n}\n#qr-spoiler-label {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n text-align: right;\n}\n/* Dumping UI */\n.dump #dump-list-container {\n display: block;\n}\n#dump-list-container {\n display: none;\n position: relative;\n overflow-y: hidden;\n margin-top: 1px;\n}\n#dump-list {\n overflow-x: auto;\n overflow-y: hidden;\n white-space: pre;\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-list:hover {\n overflow-x: auto;\n}\n.qr-preview {\n " + Style.sizing + ": border-box;\n counter-increment: thumbnails;\n cursor: move;\n display: inline-block;\n height: 90px;\n width: 90px;\n padding: 2px;\n opacity: .5;\n overflow: hidden;\n position: relative;\n text-shadow: 0 1px 1px #000;\n " + agent + "transition: opacity .25s ease-in-out;\n vertical-align: top;\n}\n.qr-preview:hover,\n.qr-preview:focus {\n opacity: .9;\n}\n.qr-preview::before {\n content: counter(thumbnails);\n color: #fff;\n position: absolute;\n top: 3px;\n right: 3px;\n text-shadow: 0 0 3px #000, 0 0 8px #000;\n}\n.qr-preview#selected {\n opacity: 1;\n}\n.qr-preview.drag {\n box-shadow: 0 0 10px rgba(0,0,0,.5);\n}\n.qr-preview.over {\n border-color: #fff;\n}\n.qr-preview > span {\n color: #fff;\n}\n.remove {\n background: none;\n color: #e00;\n font-weight: 700;\n padding: 3px;\n}\na:only-of-type > .remove {\n display: none;\n}\n.remove:hover::after {\n content: \" Remove\";\n}\n.qr-preview > label {\n background: rgba(0,0,0,.5);\n color: #fff;\n right: 0; bottom: 0; left: 0;\n position: absolute;\n text-align: center;\n}\n.qr-preview > label > input {\n margin: 0;\n}\n#add-post {\n cursor: pointer;\n font-size: 2em;\n position: absolute;\n top: 50%;\n right: 10px;\n " + agent + "transform: translateY(-50%);\n}\n/* Ads */\n.topad img,\n.middlead img,\n.bottomad img {\n opacity: 0.3;\n " + agent + "transition: opacity .3s linear;\n}\n.topad img:hover,\n.middlead img:hover,\n.bottomad img:hover {\n opacity: 1;\n}\n" + (_conf["Block Ads"] ? "/* AdBlock Minus */.bottomad + hr,.topad,.middlead,.bottomad { display: none;}" : "") + "\n" + (_conf["Shrink Ads"] ? ".topad a img,.middlead a img,.bottomad a img { width: 500px; height: auto;}" : "") + "\n/* Options */\n#overlay {\n position: fixed;\n z-index: 30;\n top: 0;\n right: 0;\n left: 0;\n bottom: 0;\n background: rgba(0,0,0,.5);\n}\n#appchanx-settings {\n width: auto;\n left: 15%;\n right: 15%;\n top: 15%;\n bottom: 15%;\n position: fixed;\n z-index: 31;\n padding: .3em;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.description {\n display: none;\n}\n#appchanx-settings h3,\n.section-keybinds,\n.section-mascots,\n.section-script,\n.style {\n text-align: center;\n}\n.section-keybinds table,\n.section-script fieldset,\n.section-style fieldset {\n text-align: left;\n}\n.section-keybinds table {\n margin: auto;\n}\n#appchanx-settings fieldset {\n padding: 5px 0;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n vertical-align: top;\n " + (_conf["Single Column Mode"] ? "margin: 0 auto 6px;" : "margin: 0 3px 6px;\n display: inline-block;") + "\n border: 0;\n}\n#appchanx-settings .section-advanced fieldset {\n display: block;\n margin: 0 auto 6px;\n}\n.section-advanced .selectrice {\n display: inline-block;\n clear: both;\n}\n.section-container {\n overflow: auto;\n position: absolute;\n top: 1.7em;\n right: 5px;\n bottom: 5px;\n left: 5px;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.sections-list {\n padding: 0 3px;\n float: left;\n}\n.sections-list > a {\n cursor: pointer;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px 3px 0 0;" : "") + "\n position: relative;\n padding: 0 4px;\n z-index: 1;\n height: 1.4em;\n display: inline-block;\n border-width: 1px 1px 0 1px;\n border-color: transparent;\n border-style: solid;\n}\n.credits {\n float: right;\n}\n#appchanx-settings h3 {\n margin: 0;\n}\n.section-script fieldset > div,\n.section-style fieldset > div,\n.section-advanced fieldset > div {\n overflow: visible;\n padding: 0 5px 0 7px;\n}\n#appchanx-settings tr:nth-of-type(2n+1),\n.section-script fieldset > div:nth-of-type(2n+1),\n.section-advanced fieldset > div:nth-of-type(2n+1),\n.section-style fieldset > div:nth-of-type(2n+1),\n.section-keybinds tr:nth-of-type(2n+1),\n#selectrice li:nth-of-type(2n+1) {\n background-color: rgba(0, 0, 0, 0.05);\n}\narticle li {\n margin: 10px 0 10px 2em;\n}\n#appchanx-settings .option {\n width: 50%;\n display: inline-block;\n vertical-align: bottom;\n}\n.option input {\n width: 100%;\n}\n.optionlabel {\n padding-left: 18px;\n}\n.rice + .optionlabel {\n padding-left: 0;\n}\n.section-script fieldset,\n.styleoption {\n text-align: left;\n}\n.section-style fieldset {\n width: 370px;\n}\n.section-script fieldset {\n width: 200px;\n}\n.suboptions,\n#mascotcontent,\n#themecontent {\n overflow: auto;\n position: absolute;\n top: 0;\n right: 0;\n bottom: 1.7em;\n left: 0;\n}\n.mAlign {\n height: 250px;\n vertical-align: middle;\n display: table-cell;\n}\n#themecontent {\n top: 1.7em;\n}\n#save,\n.stylesettings {\n position: absolute;\n right: 10px;\n bottom: 0;\n}\n.section-style .suboptions {\n bottom: 0;\n}\n.section-container textarea {\n font-family: monospace;\n min-height: 350px;\n resize: vertical;\n width: 100%;\n}\n/* Hover Functionality */\n#mouseover {\n z-index: 33;\n position: fixed;\n max-width: 70%;\n}\n#mouseover:empty {\n display: none;\n}\n/* Mascot Tab */\n#mascot_hide {\n padding: 3px;\n position: absolute;\n top: 2px;\n right: 18px;\n}\n#mascot_hide .rice {\n float: left;\n}\n#mascot_hide > div {\n height: 0;\n text-align: right;\n overflow: hidden;\n}\n#mascot_hide:hover > div {\n height: auto;\n}\n#mascot_hide label {\n width: 100%;\n display: block;\n clear: both;\n text-decoration: none;\n}\n.mascots {\n padding: 0;\n text-align: center;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.mascot,\n.mascotcontainer {\n overflow: hidden;\n}\n.mascot {\n position: relative;\n border: none;\n margin: 5px;\n padding: 0;\n width: 200px;\n display: inline-block;\n background-color: transparent;\n}\n.mascotcontainer {\n height: 250px;\n border: 0;\n margin: 0;\n max-height: 250px;\n cursor: pointer;\n bottom: 0;\n border-width: 0 1px 1px;\n border-style: solid;\n border-color: transparent;\n overflow: hidden;\n}\n.mascot img {\n max-width: 200px;\n}\n.mascotname,\n.mascotoptions {\n padding: 0;\n width: 100%;\n}\n.mascot .mascotoptions {\nopacity: 0;\n " + agent + "transition: opacity .3s linear;\n}\n.mascot:hover .mascotoptions {\n opacity: 1;\n}\n.mascotoptions {\n position: absolute;\n bottom: 0;\n right: 0;\n left: 0;\n}\n.mascotoptions a {\n display: inline-block;\n width: 33%;\n}\n#upload {\n position: absolute;\n width: 100px;\n left: 50%;\n margin-left: -50px;\n text-align: center;\n bottom: 0;\n}\n#mascots_batch {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Themes Tab */\n#themes h1 {\n position: absolute;\n right: 300px;\n bottom: 10px;\n margin: 0;\n " + agent + "transition: all .2s ease-in-out;\n opacity: 0;\n}\n#themes .selectedtheme h1 {\n right: 11px;\n opacity: 1;\n}\n#themeContainer {\n margin-bottom: 3px;\n}\n#addthemes {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n.theme {\n margin: 1em;\n}\n/* Theme Editor */\n#themeConf {\n position: fixed;\n " + Style.sidebarLocation[1] + ": 2px;\n " + Style.sidebarLocation[0] + ": auto;\n top: 0;\n bottom: 0;\n width: 296px;\n z-index: 10;\n}\n#themebar input {\n width: 30%;\n}\n.option .color {\n width: 10%;\n border-left: none !important;\n color: transparent !important;\n}\n.option .colorfield {\n width: 90%;\n}\n.themevar textarea {\n min-width: 100%;\n max-width: 100%;\n height: 20em;\n resize: vertical;\n}\n/* Mascot Editor */\n#mascotConf {\n position: fixed;\n height: 17em;\n bottom: 0;\n left: 50%;\n width: 500px;\n margin-left: -250px;\n overflow: auto;\n z-index: 10;\n}\n#mascotConf .option,\n#mascotConf .optionlabel {\n " + Style.sizing + ": border-box;\n width: 50%;\n display: inline-block;\n vertical-align: middle;\n}\n#mascotConf .option input {\n width: 100%;\n}\n#close {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Catalog */\n#content .navLinks,\n#info .navLinks,\n.btn-wrap {\n display: block;\n}\n.navLinks > .btn-wrap:not(:first-of-type)::before {\n content: ' - ';\n}\n.button {\n cursor: pointer;\n}\n#content .btn-wrap,\n#info .btn-wrap {\n display: inline-block;\n}\n#post-preview {\n position: absolute;\n z-index: 22;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n#settings,\n#threads,\n#info .navLinks,\n#content .navLinks {\n text-align: center;\n}\n#threads .thread {\n vertical-align: top;\n display: inline-block;\n word-wrap: break-word;\n overflow: hidden;\n margin-top: 5px;\n padding: 5px 0 3px;\n text-align: center;\n}\n.extended-small .thread,\n.small .thread {\n width: 165px;\n max-height: 320px;\n}\n.small .teaser,\n.large .teaser {\n display: none;\n}\n.extended-large .thread,\n.large .thread {\n width: 270px;\n max-height: 410px;\n}\n.extended-small .thumb,\n.small .thumb {\n max-width: 150px;\n max-height: 150px;\n}\n.panel {\n position: fixed;\n top: 50% !important;\n left: 50%;\n " + agent + "transform: translate(-50%, -50%);\n}\n.icon::after {\n display: inline-block;\n float: right;\n width: 1em;\n cursor: pointer;\n}\n.helpIcon::after {\n content: '?';\n}\n.closeIcon::after {\n content: '×';\n}\n/* Front Page */\n#logo {\n text-align: center;\n}\n#doc {\n margin: 0 auto;\n width: 1000px;\n position: relative;\n}\n#boards .boxcontent {\n vertical-align: top;\n text-align: center;\n}\n#filter-container,\n#options-container {\n float: right;\n position: relative;\n}\n#optionssmenu {\n top: 100% !important;\n left: 0 !important;\n}\n#boards .column {\n " + Style.sizing + ": border-box;\n display: inline-block;\n width: 16em;\n text-align: left;\n vertical-align: top;\n}\n.bd ul,\n.boxcontent ul {\n vertical-align: top;\n padding: 0;\n}\n.right-box .boxcontent ul {\n padding: 0 10px;\n}\n.yuimenuitem,\n.boxcontent li {\n list-style-type: none;\n}\n.bd ul {\n margin: 0;\n}\n.yuimenuitem::before {\n content: \" [ ] \";\n font-family: monospace;\n}\n.yuimenuitem-checked::before {\n content: \" [x] \"\n}\n.yui-u {\n display: inline-block;\n vertical-align: top;\n width: 475px;\n margin: 10px;\n}\n#recent-images .boxcontent {\n text-align: center;\n}\n#ft {\n text-align: center;\n}\n#ft ul {\n padding: 0;\n}\n#ft li {\n list-style-type: none;\n display: inline-block;\n width: 100px;\n}\n#preview-tooltip-nws,\n#preview-tooltip-ws,\n#ft .fill,\n.clear-bug {\n display: none;\n}"; + }[_conf['Post Form Style']] || "") + "\n\n" + (_conf['Post Form Style'] !== 'tabbed slideout' ? (!(_conf['Post Form Style'] === 'float' || _conf['Show Post Form Header']) ? "#qrtab { display: none; }" : _conf['Post Form Style'] !== 'slideout' ? ".autohide:not(:hover):not(.has-focus) > form { display: none !important; }" : "") + "#qrtab { margin-bottom: 1px; }" : "") + "\n\n" + (_conf['Post Form Style'] !== 'float' && _conf["Post Form Slideout Transitions"] ? "#qr { " + agent + "transition: " + agent + "transform .3s ease-in-out 1s;}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transition: " + agent + "transform .3s linear;}#qrtab { " + agent + "transition: opacity .3s ease-in-out 1s;}#qr:hover #qrtab { " + agent + "transition: opacity .3s linear;}" : "") + "\n\n#qr .close {\n float: right;\n padding: 0 3px;\n}\n#qr .warning {\n min-height: 1.6em;\n vertical-align: middle;\n padding: 0 1px;\n border-width: 1px;\n border-style: solid;\n}\n.persona {\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-button {\n width: 10%;\n margin: 0;\n}\n\n" + (_conf['Compact Post Form Inputs'] ? ".persona input.field { width: 29.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 14.8em; min-height: 9em;}#qr.has-captcha textarea.field { height: 9em;}" : ".persona input.field { width: 100%;}.persona input.field[name='name'] { width: 89.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 11.6em; min-height: 6em;}#qr.has-captcha textarea.field { height: 6em;}") + "\n\n" + (_conf["Tripcode Hider"] ? ".tripped:not(:hover):not(:focus) { opacity: 0;}" : "") + "\n\n#qr textarea {\n resize: " + _conf['Textarea Resize'] + ";\n}\n.captcha-img {\n margin: 1px 0 0;\n text-align: center;\n line-height: 0;\n}\n.captcha-img img {\n width: 100%;\n height: 4em;\n width: 246px;\n}\n.captcha-input {\n width: 100%;\n margin: 1px 0 0;\n}\n.field,\n.selectrice,\nbutton,\ninput:not([type=radio]) {\n " + Style.sizing + ": border-box;\n font-size: " + (parseInt(_conf['Font Size'], 10)) + "px;\n height: 1.6em;\n margin: 1px 0 0;\n vertical-align: bottom;\n padding: 0 1px;\n}\n.selectrice {\n padding-right: 1.6em;\n}\n#qr textarea {\n min-width: 100%;\n}\n#qr [type='submit'] {\n width: 25%;\n}\n[type='file'] {\n position: absolute;\n opacity: 0;\n z-index: -1;\n}\n#showQR {\n display: " + (_conf["Hide Show Post Form"] ? "none" : "block") + ";\n z-index: 4;\n " + Style.sidebarLocation[0] + ": 2px;\n width: " + width + "px;\n background-color: transparent;\n text-align: center;\n position: fixed;\n top: auto;\n}\n/* Fake File Input */\n#qr-filename,\n.has-file #qr-no-file {\n display: none;\n}\n#qr-no-file,\n.has-file #qr-filename {\n display: block;\n}\n#qr-filename-container {\n " + Style.sizing + ": border-box;\n display: inline-block;\n position: relative;\n width: 100px;\n min-width: 74.6%;\n max-width: 74.6%;\n margin-right: 0.4%;\n overflow: hidden;\n padding: 2px 1px 0;\n}\n#qr-filerm {\n position: absolute;\n right: 3px;\n top: 2px;\n z-index: 2;\n}\n/* Thread Select / Spoiler Label */\n#qr-thread-select {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n}\n#qr-spoiler-label {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n text-align: right;\n}\n/* Dumping UI */\n.dump #dump-list-container {\n display: block;\n}\n#dump-list-container {\n display: none;\n position: relative;\n overflow-y: hidden;\n margin-top: 1px;\n}\n#dump-list {\n overflow-x: auto;\n overflow-y: hidden;\n white-space: pre;\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-list:hover {\n overflow-x: auto;\n}\n.qr-preview {\n " + Style.sizing + ": border-box;\n counter-increment: thumbnails;\n cursor: move;\n display: inline-block;\n height: 90px;\n width: 90px;\n padding: 2px;\n opacity: .5;\n overflow: hidden;\n position: relative;\n text-shadow: 0 1px 1px #000;\n " + agent + "transition: opacity .25s ease-in-out;\n vertical-align: top;\n}\n.qr-preview:hover,\n.qr-preview:focus {\n opacity: .9;\n}\n.qr-preview::before {\n content: counter(thumbnails);\n color: #fff;\n position: absolute;\n top: 3px;\n right: 3px;\n text-shadow: 0 0 3px #000, 0 0 8px #000;\n}\n.qr-preview#selected {\n opacity: 1;\n}\n.qr-preview.drag {\n box-shadow: 0 0 10px rgba(0,0,0,.5);\n}\n.qr-preview.over {\n border-color: #fff;\n}\n.qr-preview > span {\n color: #fff;\n}\n.remove {\n background: none;\n color: #e00;\n font-weight: 700;\n padding: 3px;\n}\na:only-of-type > .remove {\n display: none;\n}\n.remove:hover::after {\n content: \" Remove\";\n}\n.qr-preview > label {\n background: rgba(0,0,0,.5);\n color: #fff;\n right: 0; bottom: 0; left: 0;\n position: absolute;\n text-align: center;\n}\n.qr-preview > label > input {\n margin: 0;\n}\n#add-post {\n cursor: pointer;\n font-size: 2em;\n position: absolute;\n top: 50%;\n right: 10px;\n " + agent + "transform: translateY(-50%);\n}\n/* Ads */\n.topad img,\n.middlead img,\n.bottomad img {\n opacity: 0.3;\n " + agent + "transition: opacity .3s linear;\n}\n.topad img:hover,\n.middlead img:hover,\n.bottomad img:hover {\n opacity: 1;\n}\n" + (_conf["Block Ads"] ? "/* AdBlock Minus */.bottomad + hr,.topad,.middlead,.bottomad { display: none;}" : "") + "\n" + (_conf["Shrink Ads"] ? ".topad a img,.middlead a img,.bottomad a img { width: 500px; height: auto;}" : "") + "\n/* Options */\n#overlay {\n position: fixed;\n z-index: 30;\n top: 0;\n right: 0;\n left: 0;\n bottom: 0;\n background: rgba(0,0,0,.5);\n}\n#appchanx-settings {\n width: auto;\n left: 15%;\n right: 15%;\n top: 15%;\n bottom: 15%;\n position: fixed;\n z-index: 31;\n padding: .3em;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.description {\n display: none;\n}\n#appchanx-settings h3,\n.section-keybinds,\n.section-mascots,\n.section-script,\n.style {\n text-align: center;\n}\n.section-keybinds table,\n.section-script fieldset,\n.section-style fieldset {\n text-align: left;\n}\n.section-keybinds table {\n margin: auto;\n}\n#appchanx-settings fieldset {\n padding: 5px 0;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n vertical-align: top;\n " + (_conf["Single Column Mode"] ? "margin: 0 auto 6px;" : "margin: 0 3px 6px;\n display: inline-block;") + "\n border: 0;\n}\n#appchanx-settings .section-advanced fieldset {\n display: block;\n margin: 0 auto 6px;\n}\n.section-advanced .selectrice {\n display: inline-block;\n clear: both;\n}\n.section-container {\n overflow: auto;\n position: absolute;\n top: 1.7em;\n right: 5px;\n bottom: 5px;\n left: 5px;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.sections-list {\n padding: 0 3px;\n float: left;\n}\n.sections-list > a {\n cursor: pointer;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px 3px 0 0;" : "") + "\n position: relative;\n padding: 0 4px;\n z-index: 1;\n height: 1.4em;\n display: inline-block;\n border-width: 1px 1px 0 1px;\n border-color: transparent;\n border-style: solid;\n}\n.credits {\n float: right;\n}\n#appchanx-settings h3 {\n margin: 0;\n}\n.section-script fieldset > div,\n.section-style fieldset > div,\n.section-advanced fieldset > div {\n overflow: visible;\n padding: 0 5px 0 7px;\n}\n#appchanx-settings tr:nth-of-type(2n+1),\n.section-script fieldset > div:nth-of-type(2n+1),\n.section-advanced fieldset > div:nth-of-type(2n+1),\n.section-style fieldset > div:nth-of-type(2n+1),\n.section-keybinds tr:nth-of-type(2n+1),\n#selectrice li:nth-of-type(2n+1) {\n background-color: rgba(0, 0, 0, 0.05);\n}\narticle li {\n margin: 10px 0 10px 2em;\n}\n#appchanx-settings .option {\n width: 50%;\n display: inline-block;\n vertical-align: bottom;\n}\n.option input {\n width: 100%;\n}\n.optionlabel {\n padding-left: 18px;\n}\n.rice + .optionlabel {\n padding-left: 0;\n}\n.section-script fieldset,\n.styleoption {\n text-align: left;\n}\n.section-style fieldset {\n width: 370px;\n}\n.section-script fieldset {\n width: 200px;\n}\n.suboptions {\n overflow: auto;\n position: absolute;\n top: 0;\n right: 0;\n bottom: 1.7em;\n left: 0;\n}\n.mAlign {\n height: 250px;\n vertical-align: middle;\n display: table-cell;\n}\n#save,\n.stylesettings {\n position: absolute;\n right: 10px;\n bottom: 0;\n}\n.section-style .suboptions {\n bottom: 0;\n}\n.section-container textarea {\n font-family: monospace;\n min-height: 350px;\n resize: vertical;\n width: 100%;\n}\n/* Hover Functionality */\n#mouseover {\n z-index: 33;\n position: fixed;\n max-width: 70%;\n}\n#mouseover:empty {\n display: none;\n}\n/* Mascot Tab */\n#mascot_hide {\n padding: 3px;\n position: absolute;\n top: 2px;\n right: 18px;\n}\n#mascot_hide .rice {\n float: left;\n}\n#mascot_hide > div {\n height: 0;\n text-align: right;\n overflow: hidden;\n}\n#mascot_hide:hover > div {\n height: auto;\n}\n#mascot_hide label {\n width: 100%;\n display: block;\n clear: both;\n text-decoration: none;\n}\n.mascots {\n padding: 0;\n text-align: center;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.mascot,\n.mascotcontainer {\n overflow: hidden;\n}\n.mascot {\n position: relative;\n border: none;\n margin: 5px;\n padding: 0;\n width: 200px;\n display: inline-block;\n background-color: transparent;\n}\n.mascotcontainer {\n height: 250px;\n border: 0;\n margin: 0;\n max-height: 250px;\n cursor: pointer;\n bottom: 0;\n border-width: 0 1px 1px;\n border-style: solid;\n border-color: transparent;\n overflow: hidden;\n}\n.mascot img {\n max-width: 200px;\n}\n.mascotname,\n.mascotoptions {\n padding: 0;\n width: 100%;\n}\n.mascot .mascotoptions {\nopacity: 0;\n " + agent + "transition: opacity .3s linear;\n}\n.mascot:hover .mascotoptions {\n opacity: 1;\n}\n.mascotoptions {\n position: absolute;\n bottom: 0;\n right: 0;\n left: 0;\n}\n.mascotoptions a {\n display: inline-block;\n width: 33%;\n}\n#upload {\n position: absolute;\n width: 100px;\n left: 50%;\n margin-left: -50px;\n text-align: center;\n bottom: 0;\n}\n#mascots_batch {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Themes Tab */\n#themes h1 {\n position: absolute;\n right: 300px;\n bottom: 10px;\n margin: 0;\n " + agent + "transition: all .2s ease-in-out;\n opacity: 0;\n}\n#themes .selectedtheme h1 {\n right: 11px;\n opacity: 1;\n}\n#addthemes {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n.theme {\n margin: 1em;\n}\n/* Theme Editor */\n#themeConf {\n position: fixed;\n " + Style.sidebarLocation[1] + ": 2px;\n " + Style.sidebarLocation[0] + ": auto;\n top: 0;\n bottom: 0;\n width: 296px;\n z-index: 10;\n}\n#themebar input {\n width: 30%;\n}\n.option .color {\n width: 10%;\n border-left: none !important;\n color: transparent !important;\n}\n.option .colorfield {\n width: 90%;\n}\n.themevar textarea {\n min-width: 100%;\n max-width: 100%;\n height: 20em;\n resize: vertical;\n}\n/* Mascot Editor */\n#mascotConf {\n position: fixed;\n height: 17em;\n bottom: 0;\n left: 50%;\n width: 500px;\n margin-left: -250px;\n overflow: auto;\n z-index: 10;\n}\n#mascotConf .option,\n#mascotConf .optionlabel {\n " + Style.sizing + ": border-box;\n width: 50%;\n display: inline-block;\n vertical-align: middle;\n}\n#mascotConf .option input {\n width: 100%;\n}\n#close {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Catalog */\n#content .navLinks,\n#info .navLinks,\n.btn-wrap {\n display: block;\n}\n.navLinks > .btn-wrap:not(:first-of-type)::before {\n content: ' - ';\n}\n.button {\n cursor: pointer;\n}\n#content .btn-wrap,\n#info .btn-wrap {\n display: inline-block;\n}\n#post-preview {\n position: absolute;\n z-index: 22;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n#settings,\n#threads,\n#info .navLinks,\n#content .navLinks {\n text-align: center;\n}\n#threads .thread {\n vertical-align: top;\n display: inline-block;\n word-wrap: break-word;\n overflow: hidden;\n margin-top: 5px;\n padding: 5px 0 3px;\n text-align: center;\n}\n.extended-small .thread,\n.small .thread {\n width: 165px;\n max-height: 320px;\n}\n.small .teaser,\n.large .teaser {\n display: none;\n}\n.extended-large .thread,\n.large .thread {\n width: 270px;\n max-height: 410px;\n}\n.extended-small .thumb,\n.small .thumb {\n max-width: 150px;\n max-height: 150px;\n}\n.panel {\n position: fixed;\n top: 50% !important;\n left: 50%;\n " + agent + "transform: translate(-50%, -50%);\n}\n.icon::after {\n display: inline-block;\n float: right;\n width: 1em;\n cursor: pointer;\n}\n.helpIcon::after {\n content: '?';\n}\n.closeIcon::after {\n content: '×';\n}\n/* Front Page */\n#logo {\n text-align: center;\n}\n#doc {\n margin: 0 auto;\n width: 1000px;\n position: relative;\n}\n#boards .boxcontent {\n vertical-align: top;\n text-align: center;\n}\n#filter-container,\n#options-container {\n float: right;\n position: relative;\n}\n#optionssmenu {\n top: 100% !important;\n left: 0 !important;\n}\n#boards .column {\n " + Style.sizing + ": border-box;\n display: inline-block;\n width: 16em;\n text-align: left;\n vertical-align: top;\n}\n.bd ul,\n.boxcontent ul {\n vertical-align: top;\n padding: 0;\n}\n.right-box .boxcontent ul {\n padding: 0 10px;\n}\n.yuimenuitem,\n.boxcontent li {\n list-style-type: none;\n}\n.bd ul {\n margin: 0;\n}\n.yuimenuitem::before {\n content: \" [ ] \";\n font-family: monospace;\n}\n.yuimenuitem-checked::before {\n content: \" [x] \"\n}\n.yui-u {\n display: inline-block;\n vertical-align: top;\n width: 475px;\n margin: 10px;\n}\n#recent-images .boxcontent {\n text-align: center;\n}\n#ft {\n text-align: center;\n}\n#ft ul {\n padding: 0;\n}\n#ft li {\n list-style-type: none;\n display: inline-block;\n width: 100px;\n}\n#preview-tooltip-nws,\n#preview-tooltip-ws,\n#ft .fill,\n.clear-bug {\n display: none;\n}"; }, theme: function(theme) { var agent, background, backgroundC, bgColor, css, fileHeading, icons, replyHeading, _conf; @@ -13795,7 +13797,7 @@ }); }, mascots: function(section, mode) { - var batchmascots, categories, cb, header, keys, mascot, mascotEl, mascotHide, menu, name, option, parentdiv, suboptions, _i, _j, _k, _len, _len1, _len2, _ref; + var batchmascots, categories, cb, keys, mascot, mascotEl, mascotHide, menu, name, node, nodes, option, suboptions, _i, _j, _k, _l, _len, _len1, _len2, _len3, _len4, _m, _ref, _ref1, _ref2; categories = {}; menu = []; @@ -13803,9 +13805,6 @@ if (typeof mode !== 'string') { mode = 'default'; } - parentdiv = $.el("div", { - id: "mascotContainer" - }); suboptions = $.el("div", { className: "suboptions" }); @@ -13817,27 +13816,24 @@ keys = Object.keys(Mascots); keys.sort(); if (mode === 'default') { + nodes = {}; _ref = MascotTools.categories; for (_i = 0, _len = _ref.length; _i < _len; _i++) { name = _ref[_i]; + nodes[name] = []; categories[name] = $.el("div", { className: "mascots", - id: name + id: name, + innerHTML: "

" + name + "

" }); if (Conf["Hidden Categories"].contains(name)) { categories[name].hidden = true; } - header = $.el("h3", { - className: "mascotHeader", - textContent: name - }); menu.push(option = $.el("label", { name: name, innerHTML: "" + name })); - $.on($('input', option), 'change', Settings.cb.mascotCategory); - $.add(categories[name], header); - $.add(suboptions, categories[name]); + $.on($('input', option), 'change', cb.category); } for (_j = 0, _len1 = keys.length; _j < _len1; _j++) { name = keys[_j]; @@ -13846,34 +13842,37 @@ } mascot = Mascots[name]; mascotEl = $.el('div', { - className: 'mascot', + className: Conf[g.MASCOTSTRING].contains(name) ? 'mascot enabled' : 'mascot', id: name, innerHTML: "
" + (name.replace(/_/g, " ")) + "
EditDeleteExport
" }); - if (Conf[g.MASCOTSTRING].contains(name)) { - $.addClass(mascotEl, 'enabled'); - } $.on($('.edit', mascotEl), 'click', cb.edit); $.on($('.delete', mascotEl), 'click', cb["delete"]); $.on($('.export', mascotEl), 'click', cb["export"]); $.on(mascotEl, 'click', cb.select); if (MascotTools.categories.contains(mascot.category)) { - $.add(categories[mascot.category], mascotEl); + nodes[mascot.category].push(mascotEl); } else { - $.add(categories[MascotTools.categories[0]], mascotEl); + nodes[MascotTools.categories[0]].push(mascotEl); } } + _ref1 = MascotTools.categories; + for (_k = 0, _len2 = _ref1.length; _k < _len2; _k++) { + name = _ref1[_k]; + $.add(categories[name], nodes[name]); + $.add(suboptions, categories[name]); + } $.add($('div', mascotHide), menu); batchmascots = $.el('div', { id: "mascots_batch", - innerHTML: "Clear All /Select All /Add Mascot /Import Mascot /Undelete Mascots /Get More Mascots! " + innerHTML: " Clear All\n/\nSelect All\n/\nAdd Mascot\n/\nImport Mascot\n/\nUndelete Mascots\n/\nGet More Mascots!" }); $.on($('#clear', batchmascots), 'click', function() { - var enabledMascots, _k, _len2; + var enabledMascots, _l, _len3; enabledMascots = JSON.parse(JSON.stringify(Conf[g.MASCOTSTRING])); - for (_k = 0, _len2 = enabledMascots.length; _k < _len2; _k++) { - name = enabledMascots[_k]; + for (_l = 0, _len3 = enabledMascots.length; _l < _len3; _l++) { + name = enabledMascots[_l]; $.rmClass($.id(name), 'enabled'); } return $.set(g.MASCOTSTRING, Conf[g.MASCOTSTRING] = []); @@ -13912,12 +13911,12 @@ return Settings.openSection.apply(mascots, ['restore']); }); } else { + nodes = []; categories = $.el("div", { - className: "mascots", - id: name + className: "mascots" }); - for (_k = 0, _len2 = keys.length; _k < _len2; _k++) { - name = keys[_k]; + for (_l = 0, _len3 = keys.length; _l < _len3; _l++) { + name = keys[_l]; if (!Conf["Deleted Mascots"].contains(name)) { continue; } @@ -13927,9 +13926,10 @@ id: name, innerHTML: "
" + (name.replace(/_/g, " ")) + "
" }); - $.on(mascotEl, 'click', Settings.cb.mascot.restore); - $.add(categories, mascotEl); + $.on(mascotEl, 'click', cb.restore); + nodes.push(mascotEl); } + $.add(categories, nodes); $.add(suboptions, categories); batchmascots = $.el('div', { id: "mascots_batch", @@ -13945,9 +13945,12 @@ return Settings.openSection.apply(mascots); }); } - $.add(parentdiv, [suboptions, batchmascots, mascotHide]); - Rice.nodes(parentdiv); - return $.add(section, parentdiv); + _ref2 = [suboptions, batchmascots, mascotHide]; + for (_m = 0, _len4 = _ref2.length; _m < _len4; _m++) { + node = _ref2[_m]; + Rice.nodes(node); + } + return $.add(section, [suboptions, batchmascots, mascotHide]); }, cb: { mascot: { diff --git a/builds/appchan-x.user.js b/builds/appchan-x.user.js index 91561b4a1..4a53513fc 100644 --- a/builds/appchan-x.user.js +++ b/builds/appchan-x.user.js @@ -10543,7 +10543,7 @@ }, categories: ['Anime', 'Ponies', 'Questionable', 'Silhouette', 'Western'], dialog: function(key) { - var dialog, div, fileInput, input, item, layout, name, option, optionHTML, setting, value, _i, _len, _ref; + var dialog, div, fileInput, input, item, layout, name, nodes, option, optionHTML, setting, value, _i, _len, _ref; Conf['editMode'] = 'mascot'; if (Mascots[key]) { @@ -10570,6 +10570,7 @@ className: "reply dialog", innerHTML: "

PROTIP: Shift-Click the Mascot Image field to upload your own images!
This may have some caveats.
" }); + nodes = []; for (name in layout) { item = layout[name]; switch (item[2]) { @@ -10657,8 +10658,9 @@ return Style.addStyle(); }); } - $.add($("#mascotcontent", dialog), div); + nodes.push(div); } + $.add($("#mascotcontent", dialog), nodes); $.on($('#save > a', dialog), 'click', function() { return MascotTools.save(editMascot); }); @@ -11173,7 +11175,7 @@ "slideout": "#qrtab input,#qrtab .rice { display: none;}#qr { top: auto !important; bottom: " + Style.pfOffset + "em !important; " + Style.sidebarLocation[0] + ": 0 !important; " + Style.sidebarLocation[1] + ": auto !important; " + agent + "transform: translateX(" + xOffset + "93%);}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transform: translate(0);}", "tabbed slideout": "#qr { top: auto !important; bottom: " + Style.pfOffset + "em !important; " + Style.sidebarLocation[0] + ": 0 !important; " + Style.sidebarLocation[1] + ": auto !important; " + agent + "transform: translateX(" + xOffset + "100%);}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transform: translateX(0);}#qrtab { " + agent + "transform: rotate(" + (Style.sidebarLocation[0] === "left" ? "" : "-") + "90deg); " + agent + "transform-origin: bottom " + Style.sidebarLocation[0] + "; position: absolute; top: 0; " + Style.sidebarLocation[0] + ": 100%; width: 110px; text-align: center; border-width: 1px 1px 0 1px; cursor: default;}#qr:hover #qrtab,#qr.has-focus #qrtab,#qr.dump #qrtab { opacity: 0; " + Style.sidebarLocation[0] + ": " + (252 + Style.sidebarOffset.W) + "px;}#qrtab input,#qrtab .close,#qrtab .rice,#qrtab span { display: none;}", "transparent fade": "#qr { overflow: visible; top: auto !important; bottom: " + Style.pfOffset + "em !important; " + Style.sidebarLocation[0] + ": 2px !important; " + Style.sidebarLocation[1] + ": auto !important; opacity: 0.2; " + agent + "transition: opacity .3s ease-in-out 1s;}#qr:hover,#qr.has-focus,#qr.dump { opacity: 1; " + agent + "transition: opacity .3s linear;}" - }[_conf['Post Form Style']] || "") + "\n\n" + (_conf['Post Form Style'] !== 'tabbed slideout' ? (!(_conf['Post Form Style'] === 'float' || _conf['Show Post Form Header']) ? "#qrtab { display: none; }" : _conf['Post Form Style'] !== 'slideout' ? ".autohide:not(:hover):not(.has-focus) > form { display: none !important; }" : "") + "#qrtab { margin-bottom: 1px; }" : "") + "\n\n" + (_conf['Post Form Style'] !== 'float' && _conf["Post Form Slideout Transitions"] ? "#qr { " + agent + "transition: " + agent + "transform .3s ease-in-out 1s;}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transition: " + agent + "transform .3s linear;}#qrtab { " + agent + "transition: opacity .3s ease-in-out 1s;}#qr:hover #qrtab { " + agent + "transition: opacity .3s linear;}" : "") + "\n\n#qr .close {\n float: right;\n padding: 0 3px;\n}\n#qr .warning {\n min-height: 1.6em;\n vertical-align: middle;\n padding: 0 1px;\n border-width: 1px;\n border-style: solid;\n}\n.persona {\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-button {\n width: 10%;\n margin: 0;\n}\n\n" + (_conf['Compact Post Form Inputs'] ? ".persona input.field { width: 29.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 14.8em; min-height: 9em;}#qr.has-captcha textarea.field { height: 9em;}" : ".persona input.field { width: 100%;}.persona input.field[name='name'] { width: 89.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 11.6em; min-height: 6em;}#qr.has-captcha textarea.field { height: 6em;}") + "\n\n" + (_conf["Tripcode Hider"] ? ".tripped:not(:hover):not(:focus) { opacity: 0;}" : "") + "\n\n#qr textarea {\n resize: " + _conf['Textarea Resize'] + ";\n}\n.captcha-img {\n margin: 1px 0 0;\n text-align: center;\n line-height: 0;\n}\n.captcha-img img {\n width: 100%;\n height: 4em;\n width: 246px;\n}\n.captcha-input {\n width: 100%;\n margin: 1px 0 0;\n}\n.field,\n.selectrice,\nbutton,\ninput:not([type=radio]) {\n " + Style.sizing + ": border-box;\n font-size: " + (parseInt(_conf['Font Size'], 10)) + "px;\n height: 1.6em;\n margin: 1px 0 0;\n vertical-align: bottom;\n padding: 0 1px;\n}\n.selectrice {\n padding-right: 1.6em;\n}\n#qr textarea {\n min-width: 100%;\n}\n#qr [type='submit'] {\n width: 25%;\n}\n[type='file'] {\n position: absolute;\n opacity: 0;\n z-index: -1;\n}\n#showQR {\n display: " + (_conf["Hide Show Post Form"] ? "none" : "block") + ";\n z-index: 4;\n " + Style.sidebarLocation[0] + ": 2px;\n width: " + width + "px;\n background-color: transparent;\n text-align: center;\n position: fixed;\n top: auto;\n}\n/* Fake File Input */\n#qr-filename,\n.has-file #qr-no-file {\n display: none;\n}\n#qr-no-file,\n.has-file #qr-filename {\n display: block;\n}\n#qr-filename-container {\n " + Style.sizing + ": border-box;\n display: inline-block;\n position: relative;\n width: 100px;\n min-width: 74.6%;\n max-width: 74.6%;\n margin-right: 0.4%;\n overflow: hidden;\n padding: 2px 1px 0;\n}\n#qr-filerm {\n position: absolute;\n right: 3px;\n top: 2px;\n z-index: 2;\n}\n/* Thread Select / Spoiler Label */\n#qr-thread-select {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n}\n#qr-spoiler-label {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n text-align: right;\n}\n/* Dumping UI */\n.dump #dump-list-container {\n display: block;\n}\n#dump-list-container {\n display: none;\n position: relative;\n overflow-y: hidden;\n margin-top: 1px;\n}\n#dump-list {\n overflow-x: auto;\n overflow-y: hidden;\n white-space: pre;\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-list:hover {\n overflow-x: auto;\n}\n.qr-preview {\n " + Style.sizing + ": border-box;\n counter-increment: thumbnails;\n cursor: move;\n display: inline-block;\n height: 90px;\n width: 90px;\n padding: 2px;\n opacity: .5;\n overflow: hidden;\n position: relative;\n text-shadow: 0 1px 1px #000;\n " + agent + "transition: opacity .25s ease-in-out;\n vertical-align: top;\n}\n.qr-preview:hover,\n.qr-preview:focus {\n opacity: .9;\n}\n.qr-preview::before {\n content: counter(thumbnails);\n color: #fff;\n position: absolute;\n top: 3px;\n right: 3px;\n text-shadow: 0 0 3px #000, 0 0 8px #000;\n}\n.qr-preview#selected {\n opacity: 1;\n}\n.qr-preview.drag {\n box-shadow: 0 0 10px rgba(0,0,0,.5);\n}\n.qr-preview.over {\n border-color: #fff;\n}\n.qr-preview > span {\n color: #fff;\n}\n.remove {\n background: none;\n color: #e00;\n font-weight: 700;\n padding: 3px;\n}\na:only-of-type > .remove {\n display: none;\n}\n.remove:hover::after {\n content: \" Remove\";\n}\n.qr-preview > label {\n background: rgba(0,0,0,.5);\n color: #fff;\n right: 0; bottom: 0; left: 0;\n position: absolute;\n text-align: center;\n}\n.qr-preview > label > input {\n margin: 0;\n}\n#add-post {\n cursor: pointer;\n font-size: 2em;\n position: absolute;\n top: 50%;\n right: 10px;\n " + agent + "transform: translateY(-50%);\n}\n/* Ads */\n.topad img,\n.middlead img,\n.bottomad img {\n opacity: 0.3;\n " + agent + "transition: opacity .3s linear;\n}\n.topad img:hover,\n.middlead img:hover,\n.bottomad img:hover {\n opacity: 1;\n}\n" + (_conf["Block Ads"] ? "/* AdBlock Minus */.bottomad + hr,.topad,.middlead,.bottomad { display: none;}" : "") + "\n" + (_conf["Shrink Ads"] ? ".topad a img,.middlead a img,.bottomad a img { width: 500px; height: auto;}" : "") + "\n/* Options */\n#overlay {\n position: fixed;\n z-index: 30;\n top: 0;\n right: 0;\n left: 0;\n bottom: 0;\n background: rgba(0,0,0,.5);\n}\n#appchanx-settings {\n width: auto;\n left: 15%;\n right: 15%;\n top: 15%;\n bottom: 15%;\n position: fixed;\n z-index: 31;\n padding: .3em;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.description {\n display: none;\n}\n#appchanx-settings h3,\n.section-keybinds,\n.section-mascots,\n.section-script,\n.style {\n text-align: center;\n}\n.section-keybinds table,\n.section-script fieldset,\n.section-style fieldset {\n text-align: left;\n}\n.section-keybinds table {\n margin: auto;\n}\n#appchanx-settings fieldset {\n padding: 5px 0;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n vertical-align: top;\n " + (_conf["Single Column Mode"] ? "margin: 0 auto 6px;" : "margin: 0 3px 6px;\n display: inline-block;") + "\n border: 0;\n}\n#appchanx-settings .section-advanced fieldset {\n display: block;\n margin: 0 auto 6px;\n}\n.section-advanced .selectrice {\n display: inline-block;\n clear: both;\n}\n.section-container {\n overflow: auto;\n position: absolute;\n top: 1.7em;\n right: 5px;\n bottom: 5px;\n left: 5px;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.sections-list {\n padding: 0 3px;\n float: left;\n}\n.sections-list > a {\n cursor: pointer;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px 3px 0 0;" : "") + "\n position: relative;\n padding: 0 4px;\n z-index: 1;\n height: 1.4em;\n display: inline-block;\n border-width: 1px 1px 0 1px;\n border-color: transparent;\n border-style: solid;\n}\n.credits {\n float: right;\n}\n#appchanx-settings h3 {\n margin: 0;\n}\n.section-script fieldset > div,\n.section-style fieldset > div,\n.section-advanced fieldset > div {\n overflow: visible;\n padding: 0 5px 0 7px;\n}\n#appchanx-settings tr:nth-of-type(2n+1),\n.section-script fieldset > div:nth-of-type(2n+1),\n.section-advanced fieldset > div:nth-of-type(2n+1),\n.section-style fieldset > div:nth-of-type(2n+1),\n.section-keybinds tr:nth-of-type(2n+1),\n#selectrice li:nth-of-type(2n+1) {\n background-color: rgba(0, 0, 0, 0.05);\n}\narticle li {\n margin: 10px 0 10px 2em;\n}\n#appchanx-settings .option {\n width: 50%;\n display: inline-block;\n vertical-align: bottom;\n}\n.option input {\n width: 100%;\n}\n.optionlabel {\n padding-left: 18px;\n}\n.rice + .optionlabel {\n padding-left: 0;\n}\n.section-script fieldset,\n.styleoption {\n text-align: left;\n}\n.section-style fieldset {\n width: 370px;\n}\n.section-script fieldset {\n width: 200px;\n}\n.suboptions,\n#mascotcontent,\n#themecontent {\n overflow: auto;\n position: absolute;\n top: 0;\n right: 0;\n bottom: 1.7em;\n left: 0;\n}\n.mAlign {\n height: 250px;\n vertical-align: middle;\n display: table-cell;\n}\n#themecontent {\n top: 1.7em;\n}\n#save,\n.stylesettings {\n position: absolute;\n right: 10px;\n bottom: 0;\n}\n.section-style .suboptions {\n bottom: 0;\n}\n.section-container textarea {\n font-family: monospace;\n min-height: 350px;\n resize: vertical;\n width: 100%;\n}\n/* Hover Functionality */\n#mouseover {\n z-index: 33;\n position: fixed;\n max-width: 70%;\n}\n#mouseover:empty {\n display: none;\n}\n/* Mascot Tab */\n#mascot_hide {\n padding: 3px;\n position: absolute;\n top: 2px;\n right: 18px;\n}\n#mascot_hide .rice {\n float: left;\n}\n#mascot_hide > div {\n height: 0;\n text-align: right;\n overflow: hidden;\n}\n#mascot_hide:hover > div {\n height: auto;\n}\n#mascot_hide label {\n width: 100%;\n display: block;\n clear: both;\n text-decoration: none;\n}\n.mascots {\n padding: 0;\n text-align: center;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.mascot,\n.mascotcontainer {\n overflow: hidden;\n}\n.mascot {\n position: relative;\n border: none;\n margin: 5px;\n padding: 0;\n width: 200px;\n display: inline-block;\n background-color: transparent;\n}\n.mascotcontainer {\n height: 250px;\n border: 0;\n margin: 0;\n max-height: 250px;\n cursor: pointer;\n bottom: 0;\n border-width: 0 1px 1px;\n border-style: solid;\n border-color: transparent;\n overflow: hidden;\n}\n.mascot img {\n max-width: 200px;\n}\n.mascotname,\n.mascotoptions {\n padding: 0;\n width: 100%;\n}\n.mascot .mascotoptions {\nopacity: 0;\n " + agent + "transition: opacity .3s linear;\n}\n.mascot:hover .mascotoptions {\n opacity: 1;\n}\n.mascotoptions {\n position: absolute;\n bottom: 0;\n right: 0;\n left: 0;\n}\n.mascotoptions a {\n display: inline-block;\n width: 33%;\n}\n#upload {\n position: absolute;\n width: 100px;\n left: 50%;\n margin-left: -50px;\n text-align: center;\n bottom: 0;\n}\n#mascots_batch {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Themes Tab */\n#themes h1 {\n position: absolute;\n right: 300px;\n bottom: 10px;\n margin: 0;\n " + agent + "transition: all .2s ease-in-out;\n opacity: 0;\n}\n#themes .selectedtheme h1 {\n right: 11px;\n opacity: 1;\n}\n#themeContainer {\n margin-bottom: 3px;\n}\n#addthemes {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n.theme {\n margin: 1em;\n}\n/* Theme Editor */\n#themeConf {\n position: fixed;\n " + Style.sidebarLocation[1] + ": 2px;\n " + Style.sidebarLocation[0] + ": auto;\n top: 0;\n bottom: 0;\n width: 296px;\n z-index: 10;\n}\n#themebar input {\n width: 30%;\n}\n.option .color {\n width: 10%;\n border-left: none !important;\n color: transparent !important;\n}\n.option .colorfield {\n width: 90%;\n}\n.themevar textarea {\n min-width: 100%;\n max-width: 100%;\n height: 20em;\n resize: vertical;\n}\n/* Mascot Editor */\n#mascotConf {\n position: fixed;\n height: 17em;\n bottom: 0;\n left: 50%;\n width: 500px;\n margin-left: -250px;\n overflow: auto;\n z-index: 10;\n}\n#mascotConf .option,\n#mascotConf .optionlabel {\n " + Style.sizing + ": border-box;\n width: 50%;\n display: inline-block;\n vertical-align: middle;\n}\n#mascotConf .option input {\n width: 100%;\n}\n#close {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Catalog */\n#content .navLinks,\n#info .navLinks,\n.btn-wrap {\n display: block;\n}\n.navLinks > .btn-wrap:not(:first-of-type)::before {\n content: ' - ';\n}\n.button {\n cursor: pointer;\n}\n#content .btn-wrap,\n#info .btn-wrap {\n display: inline-block;\n}\n#post-preview {\n position: absolute;\n z-index: 22;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n#settings,\n#threads,\n#info .navLinks,\n#content .navLinks {\n text-align: center;\n}\n#threads .thread {\n vertical-align: top;\n display: inline-block;\n word-wrap: break-word;\n overflow: hidden;\n margin-top: 5px;\n padding: 5px 0 3px;\n text-align: center;\n}\n.extended-small .thread,\n.small .thread {\n width: 165px;\n max-height: 320px;\n}\n.small .teaser,\n.large .teaser {\n display: none;\n}\n.extended-large .thread,\n.large .thread {\n width: 270px;\n max-height: 410px;\n}\n.extended-small .thumb,\n.small .thumb {\n max-width: 150px;\n max-height: 150px;\n}\n.panel {\n position: fixed;\n top: 50% !important;\n left: 50%;\n " + agent + "transform: translate(-50%, -50%);\n}\n.icon::after {\n display: inline-block;\n float: right;\n width: 1em;\n cursor: pointer;\n}\n.helpIcon::after {\n content: '?';\n}\n.closeIcon::after {\n content: '×';\n}\n/* Front Page */\n#logo {\n text-align: center;\n}\n#doc {\n margin: 0 auto;\n width: 1000px;\n position: relative;\n}\n#boards .boxcontent {\n vertical-align: top;\n text-align: center;\n}\n#filter-container,\n#options-container {\n float: right;\n position: relative;\n}\n#optionssmenu {\n top: 100% !important;\n left: 0 !important;\n}\n#boards .column {\n " + Style.sizing + ": border-box;\n display: inline-block;\n width: 16em;\n text-align: left;\n vertical-align: top;\n}\n.bd ul,\n.boxcontent ul {\n vertical-align: top;\n padding: 0;\n}\n.right-box .boxcontent ul {\n padding: 0 10px;\n}\n.yuimenuitem,\n.boxcontent li {\n list-style-type: none;\n}\n.bd ul {\n margin: 0;\n}\n.yuimenuitem::before {\n content: \" [ ] \";\n font-family: monospace;\n}\n.yuimenuitem-checked::before {\n content: \" [x] \"\n}\n.yui-u {\n display: inline-block;\n vertical-align: top;\n width: 475px;\n margin: 10px;\n}\n#recent-images .boxcontent {\n text-align: center;\n}\n#ft {\n text-align: center;\n}\n#ft ul {\n padding: 0;\n}\n#ft li {\n list-style-type: none;\n display: inline-block;\n width: 100px;\n}\n#preview-tooltip-nws,\n#preview-tooltip-ws,\n#ft .fill,\n.clear-bug {\n display: none;\n}"; + }[_conf['Post Form Style']] || "") + "\n\n" + (_conf['Post Form Style'] !== 'tabbed slideout' ? (!(_conf['Post Form Style'] === 'float' || _conf['Show Post Form Header']) ? "#qrtab { display: none; }" : _conf['Post Form Style'] !== 'slideout' ? ".autohide:not(:hover):not(.has-focus) > form { display: none !important; }" : "") + "#qrtab { margin-bottom: 1px; }" : "") + "\n\n" + (_conf['Post Form Style'] !== 'float' && _conf["Post Form Slideout Transitions"] ? "#qr { " + agent + "transition: " + agent + "transform .3s ease-in-out 1s;}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transition: " + agent + "transform .3s linear;}#qrtab { " + agent + "transition: opacity .3s ease-in-out 1s;}#qr:hover #qrtab { " + agent + "transition: opacity .3s linear;}" : "") + "\n\n#qr .close {\n float: right;\n padding: 0 3px;\n}\n#qr .warning {\n min-height: 1.6em;\n vertical-align: middle;\n padding: 0 1px;\n border-width: 1px;\n border-style: solid;\n}\n.persona {\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-button {\n width: 10%;\n margin: 0;\n}\n\n" + (_conf['Compact Post Form Inputs'] ? ".persona input.field { width: 29.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 14.8em; min-height: 9em;}#qr.has-captcha textarea.field { height: 9em;}" : ".persona input.field { width: 100%;}.persona input.field[name='name'] { width: 89.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 11.6em; min-height: 6em;}#qr.has-captcha textarea.field { height: 6em;}") + "\n\n" + (_conf["Tripcode Hider"] ? ".tripped:not(:hover):not(:focus) { opacity: 0;}" : "") + "\n\n#qr textarea {\n resize: " + _conf['Textarea Resize'] + ";\n}\n.captcha-img {\n margin: 1px 0 0;\n text-align: center;\n line-height: 0;\n}\n.captcha-img img {\n width: 100%;\n height: 4em;\n width: 246px;\n}\n.captcha-input {\n width: 100%;\n margin: 1px 0 0;\n}\n.field,\n.selectrice,\nbutton,\ninput:not([type=radio]) {\n " + Style.sizing + ": border-box;\n font-size: " + (parseInt(_conf['Font Size'], 10)) + "px;\n height: 1.6em;\n margin: 1px 0 0;\n vertical-align: bottom;\n padding: 0 1px;\n}\n.selectrice {\n padding-right: 1.6em;\n}\n#qr textarea {\n min-width: 100%;\n}\n#qr [type='submit'] {\n width: 25%;\n}\n[type='file'] {\n position: absolute;\n opacity: 0;\n z-index: -1;\n}\n#showQR {\n display: " + (_conf["Hide Show Post Form"] ? "none" : "block") + ";\n z-index: 4;\n " + Style.sidebarLocation[0] + ": 2px;\n width: " + width + "px;\n background-color: transparent;\n text-align: center;\n position: fixed;\n top: auto;\n}\n/* Fake File Input */\n#qr-filename,\n.has-file #qr-no-file {\n display: none;\n}\n#qr-no-file,\n.has-file #qr-filename {\n display: block;\n}\n#qr-filename-container {\n " + Style.sizing + ": border-box;\n display: inline-block;\n position: relative;\n width: 100px;\n min-width: 74.6%;\n max-width: 74.6%;\n margin-right: 0.4%;\n overflow: hidden;\n padding: 2px 1px 0;\n}\n#qr-filerm {\n position: absolute;\n right: 3px;\n top: 2px;\n z-index: 2;\n}\n/* Thread Select / Spoiler Label */\n#qr-thread-select {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n}\n#qr-spoiler-label {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n text-align: right;\n}\n/* Dumping UI */\n.dump #dump-list-container {\n display: block;\n}\n#dump-list-container {\n display: none;\n position: relative;\n overflow-y: hidden;\n margin-top: 1px;\n}\n#dump-list {\n overflow-x: auto;\n overflow-y: hidden;\n white-space: pre;\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-list:hover {\n overflow-x: auto;\n}\n.qr-preview {\n " + Style.sizing + ": border-box;\n counter-increment: thumbnails;\n cursor: move;\n display: inline-block;\n height: 90px;\n width: 90px;\n padding: 2px;\n opacity: .5;\n overflow: hidden;\n position: relative;\n text-shadow: 0 1px 1px #000;\n " + agent + "transition: opacity .25s ease-in-out;\n vertical-align: top;\n}\n.qr-preview:hover,\n.qr-preview:focus {\n opacity: .9;\n}\n.qr-preview::before {\n content: counter(thumbnails);\n color: #fff;\n position: absolute;\n top: 3px;\n right: 3px;\n text-shadow: 0 0 3px #000, 0 0 8px #000;\n}\n.qr-preview#selected {\n opacity: 1;\n}\n.qr-preview.drag {\n box-shadow: 0 0 10px rgba(0,0,0,.5);\n}\n.qr-preview.over {\n border-color: #fff;\n}\n.qr-preview > span {\n color: #fff;\n}\n.remove {\n background: none;\n color: #e00;\n font-weight: 700;\n padding: 3px;\n}\na:only-of-type > .remove {\n display: none;\n}\n.remove:hover::after {\n content: \" Remove\";\n}\n.qr-preview > label {\n background: rgba(0,0,0,.5);\n color: #fff;\n right: 0; bottom: 0; left: 0;\n position: absolute;\n text-align: center;\n}\n.qr-preview > label > input {\n margin: 0;\n}\n#add-post {\n cursor: pointer;\n font-size: 2em;\n position: absolute;\n top: 50%;\n right: 10px;\n " + agent + "transform: translateY(-50%);\n}\n/* Ads */\n.topad img,\n.middlead img,\n.bottomad img {\n opacity: 0.3;\n " + agent + "transition: opacity .3s linear;\n}\n.topad img:hover,\n.middlead img:hover,\n.bottomad img:hover {\n opacity: 1;\n}\n" + (_conf["Block Ads"] ? "/* AdBlock Minus */.bottomad + hr,.topad,.middlead,.bottomad { display: none;}" : "") + "\n" + (_conf["Shrink Ads"] ? ".topad a img,.middlead a img,.bottomad a img { width: 500px; height: auto;}" : "") + "\n/* Options */\n#overlay {\n position: fixed;\n z-index: 30;\n top: 0;\n right: 0;\n left: 0;\n bottom: 0;\n background: rgba(0,0,0,.5);\n}\n#appchanx-settings {\n width: auto;\n left: 15%;\n right: 15%;\n top: 15%;\n bottom: 15%;\n position: fixed;\n z-index: 31;\n padding: .3em;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.description {\n display: none;\n}\n#appchanx-settings h3,\n.section-keybinds,\n.section-mascots,\n.section-script,\n.style {\n text-align: center;\n}\n.section-keybinds table,\n.section-script fieldset,\n.section-style fieldset {\n text-align: left;\n}\n.section-keybinds table {\n margin: auto;\n}\n#appchanx-settings fieldset {\n padding: 5px 0;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n vertical-align: top;\n " + (_conf["Single Column Mode"] ? "margin: 0 auto 6px;" : "margin: 0 3px 6px;\n display: inline-block;") + "\n border: 0;\n}\n#appchanx-settings .section-advanced fieldset {\n display: block;\n margin: 0 auto 6px;\n}\n.section-advanced .selectrice {\n display: inline-block;\n clear: both;\n}\n.section-container {\n overflow: auto;\n position: absolute;\n top: 1.7em;\n right: 5px;\n bottom: 5px;\n left: 5px;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.sections-list {\n padding: 0 3px;\n float: left;\n}\n.sections-list > a {\n cursor: pointer;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px 3px 0 0;" : "") + "\n position: relative;\n padding: 0 4px;\n z-index: 1;\n height: 1.4em;\n display: inline-block;\n border-width: 1px 1px 0 1px;\n border-color: transparent;\n border-style: solid;\n}\n.credits {\n float: right;\n}\n#appchanx-settings h3 {\n margin: 0;\n}\n.section-script fieldset > div,\n.section-style fieldset > div,\n.section-advanced fieldset > div {\n overflow: visible;\n padding: 0 5px 0 7px;\n}\n#appchanx-settings tr:nth-of-type(2n+1),\n.section-script fieldset > div:nth-of-type(2n+1),\n.section-advanced fieldset > div:nth-of-type(2n+1),\n.section-style fieldset > div:nth-of-type(2n+1),\n.section-keybinds tr:nth-of-type(2n+1),\n#selectrice li:nth-of-type(2n+1) {\n background-color: rgba(0, 0, 0, 0.05);\n}\narticle li {\n margin: 10px 0 10px 2em;\n}\n#appchanx-settings .option {\n width: 50%;\n display: inline-block;\n vertical-align: bottom;\n}\n.option input {\n width: 100%;\n}\n.optionlabel {\n padding-left: 18px;\n}\n.rice + .optionlabel {\n padding-left: 0;\n}\n.section-script fieldset,\n.styleoption {\n text-align: left;\n}\n.section-style fieldset {\n width: 370px;\n}\n.section-script fieldset {\n width: 200px;\n}\n.suboptions {\n overflow: auto;\n position: absolute;\n top: 0;\n right: 0;\n bottom: 1.7em;\n left: 0;\n}\n.mAlign {\n height: 250px;\n vertical-align: middle;\n display: table-cell;\n}\n#save,\n.stylesettings {\n position: absolute;\n right: 10px;\n bottom: 0;\n}\n.section-style .suboptions {\n bottom: 0;\n}\n.section-container textarea {\n font-family: monospace;\n min-height: 350px;\n resize: vertical;\n width: 100%;\n}\n/* Hover Functionality */\n#mouseover {\n z-index: 33;\n position: fixed;\n max-width: 70%;\n}\n#mouseover:empty {\n display: none;\n}\n/* Mascot Tab */\n#mascot_hide {\n padding: 3px;\n position: absolute;\n top: 2px;\n right: 18px;\n}\n#mascot_hide .rice {\n float: left;\n}\n#mascot_hide > div {\n height: 0;\n text-align: right;\n overflow: hidden;\n}\n#mascot_hide:hover > div {\n height: auto;\n}\n#mascot_hide label {\n width: 100%;\n display: block;\n clear: both;\n text-decoration: none;\n}\n.mascots {\n padding: 0;\n text-align: center;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.mascot,\n.mascotcontainer {\n overflow: hidden;\n}\n.mascot {\n position: relative;\n border: none;\n margin: 5px;\n padding: 0;\n width: 200px;\n display: inline-block;\n background-color: transparent;\n}\n.mascotcontainer {\n height: 250px;\n border: 0;\n margin: 0;\n max-height: 250px;\n cursor: pointer;\n bottom: 0;\n border-width: 0 1px 1px;\n border-style: solid;\n border-color: transparent;\n overflow: hidden;\n}\n.mascot img {\n max-width: 200px;\n}\n.mascotname,\n.mascotoptions {\n padding: 0;\n width: 100%;\n}\n.mascot .mascotoptions {\nopacity: 0;\n " + agent + "transition: opacity .3s linear;\n}\n.mascot:hover .mascotoptions {\n opacity: 1;\n}\n.mascotoptions {\n position: absolute;\n bottom: 0;\n right: 0;\n left: 0;\n}\n.mascotoptions a {\n display: inline-block;\n width: 33%;\n}\n#upload {\n position: absolute;\n width: 100px;\n left: 50%;\n margin-left: -50px;\n text-align: center;\n bottom: 0;\n}\n#mascots_batch {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Themes Tab */\n#themes h1 {\n position: absolute;\n right: 300px;\n bottom: 10px;\n margin: 0;\n " + agent + "transition: all .2s ease-in-out;\n opacity: 0;\n}\n#themes .selectedtheme h1 {\n right: 11px;\n opacity: 1;\n}\n#addthemes {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n.theme {\n margin: 1em;\n}\n/* Theme Editor */\n#themeConf {\n position: fixed;\n " + Style.sidebarLocation[1] + ": 2px;\n " + Style.sidebarLocation[0] + ": auto;\n top: 0;\n bottom: 0;\n width: 296px;\n z-index: 10;\n}\n#themebar input {\n width: 30%;\n}\n.option .color {\n width: 10%;\n border-left: none !important;\n color: transparent !important;\n}\n.option .colorfield {\n width: 90%;\n}\n.themevar textarea {\n min-width: 100%;\n max-width: 100%;\n height: 20em;\n resize: vertical;\n}\n/* Mascot Editor */\n#mascotConf {\n position: fixed;\n height: 17em;\n bottom: 0;\n left: 50%;\n width: 500px;\n margin-left: -250px;\n overflow: auto;\n z-index: 10;\n}\n#mascotConf .option,\n#mascotConf .optionlabel {\n " + Style.sizing + ": border-box;\n width: 50%;\n display: inline-block;\n vertical-align: middle;\n}\n#mascotConf .option input {\n width: 100%;\n}\n#close {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Catalog */\n#content .navLinks,\n#info .navLinks,\n.btn-wrap {\n display: block;\n}\n.navLinks > .btn-wrap:not(:first-of-type)::before {\n content: ' - ';\n}\n.button {\n cursor: pointer;\n}\n#content .btn-wrap,\n#info .btn-wrap {\n display: inline-block;\n}\n#post-preview {\n position: absolute;\n z-index: 22;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n#settings,\n#threads,\n#info .navLinks,\n#content .navLinks {\n text-align: center;\n}\n#threads .thread {\n vertical-align: top;\n display: inline-block;\n word-wrap: break-word;\n overflow: hidden;\n margin-top: 5px;\n padding: 5px 0 3px;\n text-align: center;\n}\n.extended-small .thread,\n.small .thread {\n width: 165px;\n max-height: 320px;\n}\n.small .teaser,\n.large .teaser {\n display: none;\n}\n.extended-large .thread,\n.large .thread {\n width: 270px;\n max-height: 410px;\n}\n.extended-small .thumb,\n.small .thumb {\n max-width: 150px;\n max-height: 150px;\n}\n.panel {\n position: fixed;\n top: 50% !important;\n left: 50%;\n " + agent + "transform: translate(-50%, -50%);\n}\n.icon::after {\n display: inline-block;\n float: right;\n width: 1em;\n cursor: pointer;\n}\n.helpIcon::after {\n content: '?';\n}\n.closeIcon::after {\n content: '×';\n}\n/* Front Page */\n#logo {\n text-align: center;\n}\n#doc {\n margin: 0 auto;\n width: 1000px;\n position: relative;\n}\n#boards .boxcontent {\n vertical-align: top;\n text-align: center;\n}\n#filter-container,\n#options-container {\n float: right;\n position: relative;\n}\n#optionssmenu {\n top: 100% !important;\n left: 0 !important;\n}\n#boards .column {\n " + Style.sizing + ": border-box;\n display: inline-block;\n width: 16em;\n text-align: left;\n vertical-align: top;\n}\n.bd ul,\n.boxcontent ul {\n vertical-align: top;\n padding: 0;\n}\n.right-box .boxcontent ul {\n padding: 0 10px;\n}\n.yuimenuitem,\n.boxcontent li {\n list-style-type: none;\n}\n.bd ul {\n margin: 0;\n}\n.yuimenuitem::before {\n content: \" [ ] \";\n font-family: monospace;\n}\n.yuimenuitem-checked::before {\n content: \" [x] \"\n}\n.yui-u {\n display: inline-block;\n vertical-align: top;\n width: 475px;\n margin: 10px;\n}\n#recent-images .boxcontent {\n text-align: center;\n}\n#ft {\n text-align: center;\n}\n#ft ul {\n padding: 0;\n}\n#ft li {\n list-style-type: none;\n display: inline-block;\n width: 100px;\n}\n#preview-tooltip-nws,\n#preview-tooltip-ws,\n#ft .fill,\n.clear-bug {\n display: none;\n}"; }, theme: function(theme) { var agent, background, backgroundC, bgColor, css, fileHeading, icons, replyHeading, _conf; @@ -13814,7 +13816,7 @@ }); }, mascots: function(section, mode) { - var batchmascots, categories, cb, header, keys, mascot, mascotEl, mascotHide, menu, name, option, parentdiv, suboptions, _i, _j, _k, _len, _len1, _len2, _ref; + var batchmascots, categories, cb, keys, mascot, mascotEl, mascotHide, menu, name, node, nodes, option, suboptions, _i, _j, _k, _l, _len, _len1, _len2, _len3, _len4, _m, _ref, _ref1, _ref2; categories = {}; menu = []; @@ -13822,9 +13824,6 @@ if (typeof mode !== 'string') { mode = 'default'; } - parentdiv = $.el("div", { - id: "mascotContainer" - }); suboptions = $.el("div", { className: "suboptions" }); @@ -13836,27 +13835,24 @@ keys = Object.keys(Mascots); keys.sort(); if (mode === 'default') { + nodes = {}; _ref = MascotTools.categories; for (_i = 0, _len = _ref.length; _i < _len; _i++) { name = _ref[_i]; + nodes[name] = []; categories[name] = $.el("div", { className: "mascots", - id: name + id: name, + innerHTML: "

" + name + "

" }); if (Conf["Hidden Categories"].contains(name)) { categories[name].hidden = true; } - header = $.el("h3", { - className: "mascotHeader", - textContent: name - }); menu.push(option = $.el("label", { name: name, innerHTML: "" + name })); - $.on($('input', option), 'change', Settings.cb.mascotCategory); - $.add(categories[name], header); - $.add(suboptions, categories[name]); + $.on($('input', option), 'change', cb.category); } for (_j = 0, _len1 = keys.length; _j < _len1; _j++) { name = keys[_j]; @@ -13865,34 +13861,37 @@ } mascot = Mascots[name]; mascotEl = $.el('div', { - className: 'mascot', + className: Conf[g.MASCOTSTRING].contains(name) ? 'mascot enabled' : 'mascot', id: name, innerHTML: "
" + (name.replace(/_/g, " ")) + "
" }); - if (Conf[g.MASCOTSTRING].contains(name)) { - $.addClass(mascotEl, 'enabled'); - } $.on($('.edit', mascotEl), 'click', cb.edit); $.on($('.delete', mascotEl), 'click', cb["delete"]); $.on($('.export', mascotEl), 'click', cb["export"]); $.on(mascotEl, 'click', cb.select); if (MascotTools.categories.contains(mascot.category)) { - $.add(categories[mascot.category], mascotEl); + nodes[mascot.category].push(mascotEl); } else { - $.add(categories[MascotTools.categories[0]], mascotEl); + nodes[MascotTools.categories[0]].push(mascotEl); } } + _ref1 = MascotTools.categories; + for (_k = 0, _len2 = _ref1.length; _k < _len2; _k++) { + name = _ref1[_k]; + $.add(categories[name], nodes[name]); + $.add(suboptions, categories[name]); + } $.add($('div', mascotHide), menu); batchmascots = $.el('div', { id: "mascots_batch", - innerHTML: "Clear All /Select All /Add Mascot /Import Mascot /Undelete Mascots /Get More Mascots! " + innerHTML: " Clear All\n/\nSelect All\n/\nAdd Mascot\n/\nImport Mascot\n/\nUndelete Mascots\n/\nGet More Mascots!" }); $.on($('#clear', batchmascots), 'click', function() { - var enabledMascots, _k, _len2; + var enabledMascots, _l, _len3; enabledMascots = JSON.parse(JSON.stringify(Conf[g.MASCOTSTRING])); - for (_k = 0, _len2 = enabledMascots.length; _k < _len2; _k++) { - name = enabledMascots[_k]; + for (_l = 0, _len3 = enabledMascots.length; _l < _len3; _l++) { + name = enabledMascots[_l]; $.rmClass($.id(name), 'enabled'); } return $.set(g.MASCOTSTRING, Conf[g.MASCOTSTRING] = []); @@ -13931,12 +13930,12 @@ return Settings.openSection.apply(mascots, ['restore']); }); } else { + nodes = []; categories = $.el("div", { - className: "mascots", - id: name + className: "mascots" }); - for (_k = 0, _len2 = keys.length; _k < _len2; _k++) { - name = keys[_k]; + for (_l = 0, _len3 = keys.length; _l < _len3; _l++) { + name = keys[_l]; if (!Conf["Deleted Mascots"].contains(name)) { continue; } @@ -13946,9 +13945,10 @@ id: name, innerHTML: "
" + (name.replace(/_/g, " ")) + "
" }); - $.on(mascotEl, 'click', Settings.cb.mascot.restore); - $.add(categories, mascotEl); + $.on(mascotEl, 'click', cb.restore); + nodes.push(mascotEl); } + $.add(categories, nodes); $.add(suboptions, categories); batchmascots = $.el('div', { id: "mascots_batch", @@ -13964,9 +13964,12 @@ return Settings.openSection.apply(mascots); }); } - $.add(parentdiv, [suboptions, batchmascots, mascotHide]); - Rice.nodes(parentdiv); - return $.add(section, parentdiv); + _ref2 = [suboptions, batchmascots, mascotHide]; + for (_m = 0, _len4 = _ref2.length; _m < _len4; _m++) { + node = _ref2[_m]; + Rice.nodes(node); + } + return $.add(section, [suboptions, batchmascots, mascotHide]); }, cb: { mascot: { diff --git a/builds/crx/script.js b/builds/crx/script.js index e5343c659..7ad83a5d1 100644 --- a/builds/crx/script.js +++ b/builds/crx/script.js @@ -10526,7 +10526,7 @@ }, categories: ['Anime', 'Ponies', 'Questionable', 'Silhouette', 'Western'], dialog: function(key) { - var dialog, div, fileInput, input, item, layout, name, option, optionHTML, setting, value, _i, _len, _ref; + var dialog, div, fileInput, input, item, layout, name, nodes, option, optionHTML, setting, value, _i, _len, _ref; Conf['editMode'] = 'mascot'; if (Mascots[key]) { @@ -10553,6 +10553,7 @@ className: "reply dialog", innerHTML: "

PROTIP: Shift-Click the Mascot Image field to upload your own images!
This may have some caveats.
" }); + nodes = []; for (name in layout) { item = layout[name]; switch (item[2]) { @@ -10640,8 +10641,9 @@ return Style.addStyle(); }); } - $.add($("#mascotcontent", dialog), div); + nodes.push(div); } + $.add($("#mascotcontent", dialog), nodes); $.on($('#save > a', dialog), 'click', function() { return MascotTools.save(editMascot); }); @@ -11156,7 +11158,7 @@ "slideout": "#qrtab input,#qrtab .rice { display: none;}#qr { top: auto !important; bottom: " + Style.pfOffset + "em !important; " + Style.sidebarLocation[0] + ": 0 !important; " + Style.sidebarLocation[1] + ": auto !important; " + agent + "transform: translateX(" + xOffset + "93%);}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transform: translate(0);}", "tabbed slideout": "#qr { top: auto !important; bottom: " + Style.pfOffset + "em !important; " + Style.sidebarLocation[0] + ": 0 !important; " + Style.sidebarLocation[1] + ": auto !important; " + agent + "transform: translateX(" + xOffset + "100%);}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transform: translateX(0);}#qrtab { " + agent + "transform: rotate(" + (Style.sidebarLocation[0] === "left" ? "" : "-") + "90deg); " + agent + "transform-origin: bottom " + Style.sidebarLocation[0] + "; position: absolute; top: 0; " + Style.sidebarLocation[0] + ": 100%; width: 110px; text-align: center; border-width: 1px 1px 0 1px; cursor: default;}#qr:hover #qrtab,#qr.has-focus #qrtab,#qr.dump #qrtab { opacity: 0; " + Style.sidebarLocation[0] + ": " + (252 + Style.sidebarOffset.W) + "px;}#qrtab input,#qrtab .close,#qrtab .rice,#qrtab span { display: none;}", "transparent fade": "#qr { overflow: visible; top: auto !important; bottom: " + Style.pfOffset + "em !important; " + Style.sidebarLocation[0] + ": 2px !important; " + Style.sidebarLocation[1] + ": auto !important; opacity: 0.2; " + agent + "transition: opacity .3s ease-in-out 1s;}#qr:hover,#qr.has-focus,#qr.dump { opacity: 1; " + agent + "transition: opacity .3s linear;}" - }[_conf['Post Form Style']] || "") + "\n\n" + (_conf['Post Form Style'] !== 'tabbed slideout' ? (!(_conf['Post Form Style'] === 'float' || _conf['Show Post Form Header']) ? "#qrtab { display: none; }" : _conf['Post Form Style'] !== 'slideout' ? ".autohide:not(:hover):not(.has-focus) > form { display: none !important; }" : "") + "#qrtab { margin-bottom: 1px; }" : "") + "\n\n" + (_conf['Post Form Style'] !== 'float' && _conf["Post Form Slideout Transitions"] ? "#qr { " + agent + "transition: " + agent + "transform .3s ease-in-out 1s;}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transition: " + agent + "transform .3s linear;}#qrtab { " + agent + "transition: opacity .3s ease-in-out 1s;}#qr:hover #qrtab { " + agent + "transition: opacity .3s linear;}" : "") + "\n\n#qr .close {\n float: right;\n padding: 0 3px;\n}\n#qr .warning {\n min-height: 1.6em;\n vertical-align: middle;\n padding: 0 1px;\n border-width: 1px;\n border-style: solid;\n}\n.persona {\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-button {\n width: 10%;\n margin: 0;\n}\n\n" + (_conf['Compact Post Form Inputs'] ? ".persona input.field { width: 29.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 14.8em; min-height: 9em;}#qr.has-captcha textarea.field { height: 9em;}" : ".persona input.field { width: 100%;}.persona input.field[name='name'] { width: 89.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 11.6em; min-height: 6em;}#qr.has-captcha textarea.field { height: 6em;}") + "\n\n" + (_conf["Tripcode Hider"] ? ".tripped:not(:hover):not(:focus) { opacity: 0;}" : "") + "\n\n#qr textarea {\n resize: " + _conf['Textarea Resize'] + ";\n}\n.captcha-img {\n margin: 1px 0 0;\n text-align: center;\n line-height: 0;\n}\n.captcha-img img {\n width: 100%;\n height: 4em;\n width: 246px;\n}\n.captcha-input {\n width: 100%;\n margin: 1px 0 0;\n}\n.field,\n.selectrice,\nbutton,\ninput:not([type=radio]) {\n " + Style.sizing + ": border-box;\n font-size: " + (parseInt(_conf['Font Size'], 10)) + "px;\n height: 1.6em;\n margin: 1px 0 0;\n vertical-align: bottom;\n padding: 0 1px;\n}\n.selectrice {\n padding-right: 1.6em;\n}\n#qr textarea {\n min-width: 100%;\n}\n#qr [type='submit'] {\n width: 25%;\n}\n[type='file'] {\n position: absolute;\n opacity: 0;\n z-index: -1;\n}\n#showQR {\n display: " + (_conf["Hide Show Post Form"] ? "none" : "block") + ";\n z-index: 4;\n " + Style.sidebarLocation[0] + ": 2px;\n width: " + width + "px;\n background-color: transparent;\n text-align: center;\n position: fixed;\n top: auto;\n}\n/* Fake File Input */\n#qr-filename,\n.has-file #qr-no-file {\n display: none;\n}\n#qr-no-file,\n.has-file #qr-filename {\n display: block;\n}\n#qr-filename-container {\n " + Style.sizing + ": border-box;\n display: inline-block;\n position: relative;\n width: 100px;\n min-width: 74.6%;\n max-width: 74.6%;\n margin-right: 0.4%;\n overflow: hidden;\n padding: 2px 1px 0;\n}\n#qr-filerm {\n position: absolute;\n right: 3px;\n top: 2px;\n z-index: 2;\n}\n/* Thread Select / Spoiler Label */\n#qr-thread-select {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n}\n#qr-spoiler-label {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n text-align: right;\n}\n/* Dumping UI */\n.dump #dump-list-container {\n display: block;\n}\n#dump-list-container {\n display: none;\n position: relative;\n overflow-y: hidden;\n margin-top: 1px;\n}\n#dump-list {\n overflow-x: auto;\n overflow-y: hidden;\n white-space: pre;\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-list:hover {\n overflow-x: auto;\n}\n.qr-preview {\n " + Style.sizing + ": border-box;\n counter-increment: thumbnails;\n cursor: move;\n display: inline-block;\n height: 90px;\n width: 90px;\n padding: 2px;\n opacity: .5;\n overflow: hidden;\n position: relative;\n text-shadow: 0 1px 1px #000;\n " + agent + "transition: opacity .25s ease-in-out;\n vertical-align: top;\n}\n.qr-preview:hover,\n.qr-preview:focus {\n opacity: .9;\n}\n.qr-preview::before {\n content: counter(thumbnails);\n color: #fff;\n position: absolute;\n top: 3px;\n right: 3px;\n text-shadow: 0 0 3px #000, 0 0 8px #000;\n}\n.qr-preview#selected {\n opacity: 1;\n}\n.qr-preview.drag {\n box-shadow: 0 0 10px rgba(0,0,0,.5);\n}\n.qr-preview.over {\n border-color: #fff;\n}\n.qr-preview > span {\n color: #fff;\n}\n.remove {\n background: none;\n color: #e00;\n font-weight: 700;\n padding: 3px;\n}\na:only-of-type > .remove {\n display: none;\n}\n.remove:hover::after {\n content: \" Remove\";\n}\n.qr-preview > label {\n background: rgba(0,0,0,.5);\n color: #fff;\n right: 0; bottom: 0; left: 0;\n position: absolute;\n text-align: center;\n}\n.qr-preview > label > input {\n margin: 0;\n}\n#add-post {\n cursor: pointer;\n font-size: 2em;\n position: absolute;\n top: 50%;\n right: 10px;\n " + agent + "transform: translateY(-50%);\n}\n/* Ads */\n.topad img,\n.middlead img,\n.bottomad img {\n opacity: 0.3;\n " + agent + "transition: opacity .3s linear;\n}\n.topad img:hover,\n.middlead img:hover,\n.bottomad img:hover {\n opacity: 1;\n}\n" + (_conf["Block Ads"] ? "/* AdBlock Minus */.bottomad + hr,.topad,.middlead,.bottomad { display: none;}" : "") + "\n" + (_conf["Shrink Ads"] ? ".topad a img,.middlead a img,.bottomad a img { width: 500px; height: auto;}" : "") + "\n/* Options */\n#overlay {\n position: fixed;\n z-index: 30;\n top: 0;\n right: 0;\n left: 0;\n bottom: 0;\n background: rgba(0,0,0,.5);\n}\n#appchanx-settings {\n width: auto;\n left: 15%;\n right: 15%;\n top: 15%;\n bottom: 15%;\n position: fixed;\n z-index: 31;\n padding: .3em;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.description {\n display: none;\n}\n#appchanx-settings h3,\n.section-keybinds,\n.section-mascots,\n.section-script,\n.style {\n text-align: center;\n}\n.section-keybinds table,\n.section-script fieldset,\n.section-style fieldset {\n text-align: left;\n}\n.section-keybinds table {\n margin: auto;\n}\n#appchanx-settings fieldset {\n padding: 5px 0;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n vertical-align: top;\n " + (_conf["Single Column Mode"] ? "margin: 0 auto 6px;" : "margin: 0 3px 6px;\n display: inline-block;") + "\n border: 0;\n}\n#appchanx-settings .section-advanced fieldset {\n display: block;\n margin: 0 auto 6px;\n}\n.section-advanced .selectrice {\n display: inline-block;\n clear: both;\n}\n.section-container {\n overflow: auto;\n position: absolute;\n top: 1.7em;\n right: 5px;\n bottom: 5px;\n left: 5px;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.sections-list {\n padding: 0 3px;\n float: left;\n}\n.sections-list > a {\n cursor: pointer;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px 3px 0 0;" : "") + "\n position: relative;\n padding: 0 4px;\n z-index: 1;\n height: 1.4em;\n display: inline-block;\n border-width: 1px 1px 0 1px;\n border-color: transparent;\n border-style: solid;\n}\n.credits {\n float: right;\n}\n#appchanx-settings h3 {\n margin: 0;\n}\n.section-script fieldset > div,\n.section-style fieldset > div,\n.section-advanced fieldset > div {\n overflow: visible;\n padding: 0 5px 0 7px;\n}\n#appchanx-settings tr:nth-of-type(2n+1),\n.section-script fieldset > div:nth-of-type(2n+1),\n.section-advanced fieldset > div:nth-of-type(2n+1),\n.section-style fieldset > div:nth-of-type(2n+1),\n.section-keybinds tr:nth-of-type(2n+1),\n#selectrice li:nth-of-type(2n+1) {\n background-color: rgba(0, 0, 0, 0.05);\n}\narticle li {\n margin: 10px 0 10px 2em;\n}\n#appchanx-settings .option {\n width: 50%;\n display: inline-block;\n vertical-align: bottom;\n}\n.option input {\n width: 100%;\n}\n.optionlabel {\n padding-left: 18px;\n}\n.rice + .optionlabel {\n padding-left: 0;\n}\n.section-script fieldset,\n.styleoption {\n text-align: left;\n}\n.section-style fieldset {\n width: 370px;\n}\n.section-script fieldset {\n width: 200px;\n}\n.suboptions,\n#mascotcontent,\n#themecontent {\n overflow: auto;\n position: absolute;\n top: 0;\n right: 0;\n bottom: 1.7em;\n left: 0;\n}\n.mAlign {\n height: 250px;\n vertical-align: middle;\n display: table-cell;\n}\n#themecontent {\n top: 1.7em;\n}\n#save,\n.stylesettings {\n position: absolute;\n right: 10px;\n bottom: 0;\n}\n.section-style .suboptions {\n bottom: 0;\n}\n.section-container textarea {\n font-family: monospace;\n min-height: 350px;\n resize: vertical;\n width: 100%;\n}\n/* Hover Functionality */\n#mouseover {\n z-index: 33;\n position: fixed;\n max-width: 70%;\n}\n#mouseover:empty {\n display: none;\n}\n/* Mascot Tab */\n#mascot_hide {\n padding: 3px;\n position: absolute;\n top: 2px;\n right: 18px;\n}\n#mascot_hide .rice {\n float: left;\n}\n#mascot_hide > div {\n height: 0;\n text-align: right;\n overflow: hidden;\n}\n#mascot_hide:hover > div {\n height: auto;\n}\n#mascot_hide label {\n width: 100%;\n display: block;\n clear: both;\n text-decoration: none;\n}\n.mascots {\n padding: 0;\n text-align: center;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.mascot,\n.mascotcontainer {\n overflow: hidden;\n}\n.mascot {\n position: relative;\n border: none;\n margin: 5px;\n padding: 0;\n width: 200px;\n display: inline-block;\n background-color: transparent;\n}\n.mascotcontainer {\n height: 250px;\n border: 0;\n margin: 0;\n max-height: 250px;\n cursor: pointer;\n bottom: 0;\n border-width: 0 1px 1px;\n border-style: solid;\n border-color: transparent;\n overflow: hidden;\n}\n.mascot img {\n max-width: 200px;\n}\n.mascotname,\n.mascotoptions {\n padding: 0;\n width: 100%;\n}\n.mascot .mascotoptions {\nopacity: 0;\n " + agent + "transition: opacity .3s linear;\n}\n.mascot:hover .mascotoptions {\n opacity: 1;\n}\n.mascotoptions {\n position: absolute;\n bottom: 0;\n right: 0;\n left: 0;\n}\n.mascotoptions a {\n display: inline-block;\n width: 33%;\n}\n#upload {\n position: absolute;\n width: 100px;\n left: 50%;\n margin-left: -50px;\n text-align: center;\n bottom: 0;\n}\n#mascots_batch {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Themes Tab */\n#themes h1 {\n position: absolute;\n right: 300px;\n bottom: 10px;\n margin: 0;\n " + agent + "transition: all .2s ease-in-out;\n opacity: 0;\n}\n#themes .selectedtheme h1 {\n right: 11px;\n opacity: 1;\n}\n#themeContainer {\n margin-bottom: 3px;\n}\n#addthemes {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n.theme {\n margin: 1em;\n}\n/* Theme Editor */\n#themeConf {\n position: fixed;\n " + Style.sidebarLocation[1] + ": 2px;\n " + Style.sidebarLocation[0] + ": auto;\n top: 0;\n bottom: 0;\n width: 296px;\n z-index: 10;\n}\n#themebar input {\n width: 30%;\n}\n.option .color {\n width: 10%;\n border-left: none !important;\n color: transparent !important;\n}\n.option .colorfield {\n width: 90%;\n}\n.themevar textarea {\n min-width: 100%;\n max-width: 100%;\n height: 20em;\n resize: vertical;\n}\n/* Mascot Editor */\n#mascotConf {\n position: fixed;\n height: 17em;\n bottom: 0;\n left: 50%;\n width: 500px;\n margin-left: -250px;\n overflow: auto;\n z-index: 10;\n}\n#mascotConf .option,\n#mascotConf .optionlabel {\n " + Style.sizing + ": border-box;\n width: 50%;\n display: inline-block;\n vertical-align: middle;\n}\n#mascotConf .option input {\n width: 100%;\n}\n#close {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Catalog */\n#content .navLinks,\n#info .navLinks,\n.btn-wrap {\n display: block;\n}\n.navLinks > .btn-wrap:not(:first-of-type)::before {\n content: ' - ';\n}\n.button {\n cursor: pointer;\n}\n#content .btn-wrap,\n#info .btn-wrap {\n display: inline-block;\n}\n#post-preview {\n position: absolute;\n z-index: 22;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n#settings,\n#threads,\n#info .navLinks,\n#content .navLinks {\n text-align: center;\n}\n#threads .thread {\n vertical-align: top;\n display: inline-block;\n word-wrap: break-word;\n overflow: hidden;\n margin-top: 5px;\n padding: 5px 0 3px;\n text-align: center;\n}\n.extended-small .thread,\n.small .thread {\n width: 165px;\n max-height: 320px;\n}\n.small .teaser,\n.large .teaser {\n display: none;\n}\n.extended-large .thread,\n.large .thread {\n width: 270px;\n max-height: 410px;\n}\n.extended-small .thumb,\n.small .thumb {\n max-width: 150px;\n max-height: 150px;\n}\n.panel {\n position: fixed;\n top: 50% !important;\n left: 50%;\n " + agent + "transform: translate(-50%, -50%);\n}\n.icon::after {\n display: inline-block;\n float: right;\n width: 1em;\n cursor: pointer;\n}\n.helpIcon::after {\n content: '?';\n}\n.closeIcon::after {\n content: '×';\n}\n/* Front Page */\n#logo {\n text-align: center;\n}\n#doc {\n margin: 0 auto;\n width: 1000px;\n position: relative;\n}\n#boards .boxcontent {\n vertical-align: top;\n text-align: center;\n}\n#filter-container,\n#options-container {\n float: right;\n position: relative;\n}\n#optionssmenu {\n top: 100% !important;\n left: 0 !important;\n}\n#boards .column {\n " + Style.sizing + ": border-box;\n display: inline-block;\n width: 16em;\n text-align: left;\n vertical-align: top;\n}\n.bd ul,\n.boxcontent ul {\n vertical-align: top;\n padding: 0;\n}\n.right-box .boxcontent ul {\n padding: 0 10px;\n}\n.yuimenuitem,\n.boxcontent li {\n list-style-type: none;\n}\n.bd ul {\n margin: 0;\n}\n.yuimenuitem::before {\n content: \" [ ] \";\n font-family: monospace;\n}\n.yuimenuitem-checked::before {\n content: \" [x] \"\n}\n.yui-u {\n display: inline-block;\n vertical-align: top;\n width: 475px;\n margin: 10px;\n}\n#recent-images .boxcontent {\n text-align: center;\n}\n#ft {\n text-align: center;\n}\n#ft ul {\n padding: 0;\n}\n#ft li {\n list-style-type: none;\n display: inline-block;\n width: 100px;\n}\n#preview-tooltip-nws,\n#preview-tooltip-ws,\n#ft .fill,\n.clear-bug {\n display: none;\n}"; + }[_conf['Post Form Style']] || "") + "\n\n" + (_conf['Post Form Style'] !== 'tabbed slideout' ? (!(_conf['Post Form Style'] === 'float' || _conf['Show Post Form Header']) ? "#qrtab { display: none; }" : _conf['Post Form Style'] !== 'slideout' ? ".autohide:not(:hover):not(.has-focus) > form { display: none !important; }" : "") + "#qrtab { margin-bottom: 1px; }" : "") + "\n\n" + (_conf['Post Form Style'] !== 'float' && _conf["Post Form Slideout Transitions"] ? "#qr { " + agent + "transition: " + agent + "transform .3s ease-in-out 1s;}#qr:hover,#qr.has-focus,#qr.dump { " + agent + "transition: " + agent + "transform .3s linear;}#qrtab { " + agent + "transition: opacity .3s ease-in-out 1s;}#qr:hover #qrtab { " + agent + "transition: opacity .3s linear;}" : "") + "\n\n#qr .close {\n float: right;\n padding: 0 3px;\n}\n#qr .warning {\n min-height: 1.6em;\n vertical-align: middle;\n padding: 0 1px;\n border-width: 1px;\n border-style: solid;\n}\n.persona {\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-button {\n width: 10%;\n margin: 0;\n}\n\n" + (_conf['Compact Post Form Inputs'] ? ".persona input.field { width: 29.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 14.8em; min-height: 9em;}#qr.has-captcha textarea.field { height: 9em;}" : ".persona input.field { width: 100%;}.persona input.field[name='name'] { width: 89.6%; margin: 0 0 0 0.4%;}#qr textarea.field { height: 11.6em; min-height: 6em;}#qr.has-captcha textarea.field { height: 6em;}") + "\n\n" + (_conf["Tripcode Hider"] ? ".tripped:not(:hover):not(:focus) { opacity: 0;}" : "") + "\n\n#qr textarea {\n resize: " + _conf['Textarea Resize'] + ";\n}\n.captcha-img {\n margin: 1px 0 0;\n text-align: center;\n line-height: 0;\n}\n.captcha-img img {\n width: 100%;\n height: 4em;\n width: 246px;\n}\n.captcha-input {\n width: 100%;\n margin: 1px 0 0;\n}\n.field,\n.selectrice,\nbutton,\ninput:not([type=radio]) {\n " + Style.sizing + ": border-box;\n font-size: " + (parseInt(_conf['Font Size'], 10)) + "px;\n height: 1.6em;\n margin: 1px 0 0;\n vertical-align: bottom;\n padding: 0 1px;\n}\n.selectrice {\n padding-right: 1.6em;\n}\n#qr textarea {\n min-width: 100%;\n}\n#qr [type='submit'] {\n width: 25%;\n}\n[type='file'] {\n position: absolute;\n opacity: 0;\n z-index: -1;\n}\n#showQR {\n display: " + (_conf["Hide Show Post Form"] ? "none" : "block") + ";\n z-index: 4;\n " + Style.sidebarLocation[0] + ": 2px;\n width: " + width + "px;\n background-color: transparent;\n text-align: center;\n position: fixed;\n top: auto;\n}\n/* Fake File Input */\n#qr-filename,\n.has-file #qr-no-file {\n display: none;\n}\n#qr-no-file,\n.has-file #qr-filename {\n display: block;\n}\n#qr-filename-container {\n " + Style.sizing + ": border-box;\n display: inline-block;\n position: relative;\n width: 100px;\n min-width: 74.6%;\n max-width: 74.6%;\n margin-right: 0.4%;\n overflow: hidden;\n padding: 2px 1px 0;\n}\n#qr-filerm {\n position: absolute;\n right: 3px;\n top: 2px;\n z-index: 2;\n}\n/* Thread Select / Spoiler Label */\n#qr-thread-select {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n}\n#qr-spoiler-label {\n vertical-align: bottom;\n width: 49%;\n display: inline-block;\n text-align: right;\n}\n/* Dumping UI */\n.dump #dump-list-container {\n display: block;\n}\n#dump-list-container {\n display: none;\n position: relative;\n overflow-y: hidden;\n margin-top: 1px;\n}\n#dump-list {\n overflow-x: auto;\n overflow-y: hidden;\n white-space: pre;\n width: 248px;\n max-width: 100%;\n min-width: 100%;\n}\n#dump-list:hover {\n overflow-x: auto;\n}\n.qr-preview {\n " + Style.sizing + ": border-box;\n counter-increment: thumbnails;\n cursor: move;\n display: inline-block;\n height: 90px;\n width: 90px;\n padding: 2px;\n opacity: .5;\n overflow: hidden;\n position: relative;\n text-shadow: 0 1px 1px #000;\n " + agent + "transition: opacity .25s ease-in-out;\n vertical-align: top;\n}\n.qr-preview:hover,\n.qr-preview:focus {\n opacity: .9;\n}\n.qr-preview::before {\n content: counter(thumbnails);\n color: #fff;\n position: absolute;\n top: 3px;\n right: 3px;\n text-shadow: 0 0 3px #000, 0 0 8px #000;\n}\n.qr-preview#selected {\n opacity: 1;\n}\n.qr-preview.drag {\n box-shadow: 0 0 10px rgba(0,0,0,.5);\n}\n.qr-preview.over {\n border-color: #fff;\n}\n.qr-preview > span {\n color: #fff;\n}\n.remove {\n background: none;\n color: #e00;\n font-weight: 700;\n padding: 3px;\n}\na:only-of-type > .remove {\n display: none;\n}\n.remove:hover::after {\n content: \" Remove\";\n}\n.qr-preview > label {\n background: rgba(0,0,0,.5);\n color: #fff;\n right: 0; bottom: 0; left: 0;\n position: absolute;\n text-align: center;\n}\n.qr-preview > label > input {\n margin: 0;\n}\n#add-post {\n cursor: pointer;\n font-size: 2em;\n position: absolute;\n top: 50%;\n right: 10px;\n " + agent + "transform: translateY(-50%);\n}\n/* Ads */\n.topad img,\n.middlead img,\n.bottomad img {\n opacity: 0.3;\n " + agent + "transition: opacity .3s linear;\n}\n.topad img:hover,\n.middlead img:hover,\n.bottomad img:hover {\n opacity: 1;\n}\n" + (_conf["Block Ads"] ? "/* AdBlock Minus */.bottomad + hr,.topad,.middlead,.bottomad { display: none;}" : "") + "\n" + (_conf["Shrink Ads"] ? ".topad a img,.middlead a img,.bottomad a img { width: 500px; height: auto;}" : "") + "\n/* Options */\n#overlay {\n position: fixed;\n z-index: 30;\n top: 0;\n right: 0;\n left: 0;\n bottom: 0;\n background: rgba(0,0,0,.5);\n}\n#appchanx-settings {\n width: auto;\n left: 15%;\n right: 15%;\n top: 15%;\n bottom: 15%;\n position: fixed;\n z-index: 31;\n padding: .3em;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.description {\n display: none;\n}\n#appchanx-settings h3,\n.section-keybinds,\n.section-mascots,\n.section-script,\n.style {\n text-align: center;\n}\n.section-keybinds table,\n.section-script fieldset,\n.section-style fieldset {\n text-align: left;\n}\n.section-keybinds table {\n margin: auto;\n}\n#appchanx-settings fieldset {\n padding: 5px 0;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n vertical-align: top;\n " + (_conf["Single Column Mode"] ? "margin: 0 auto 6px;" : "margin: 0 3px 6px;\n display: inline-block;") + "\n border: 0;\n}\n#appchanx-settings .section-advanced fieldset {\n display: block;\n margin: 0 auto 6px;\n}\n.section-advanced .selectrice {\n display: inline-block;\n clear: both;\n}\n.section-container {\n overflow: auto;\n position: absolute;\n top: 1.7em;\n right: 5px;\n bottom: 5px;\n left: 5px;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.sections-list {\n padding: 0 3px;\n float: left;\n}\n.sections-list > a {\n cursor: pointer;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px 3px 0 0;" : "") + "\n position: relative;\n padding: 0 4px;\n z-index: 1;\n height: 1.4em;\n display: inline-block;\n border-width: 1px 1px 0 1px;\n border-color: transparent;\n border-style: solid;\n}\n.credits {\n float: right;\n}\n#appchanx-settings h3 {\n margin: 0;\n}\n.section-script fieldset > div,\n.section-style fieldset > div,\n.section-advanced fieldset > div {\n overflow: visible;\n padding: 0 5px 0 7px;\n}\n#appchanx-settings tr:nth-of-type(2n+1),\n.section-script fieldset > div:nth-of-type(2n+1),\n.section-advanced fieldset > div:nth-of-type(2n+1),\n.section-style fieldset > div:nth-of-type(2n+1),\n.section-keybinds tr:nth-of-type(2n+1),\n#selectrice li:nth-of-type(2n+1) {\n background-color: rgba(0, 0, 0, 0.05);\n}\narticle li {\n margin: 10px 0 10px 2em;\n}\n#appchanx-settings .option {\n width: 50%;\n display: inline-block;\n vertical-align: bottom;\n}\n.option input {\n width: 100%;\n}\n.optionlabel {\n padding-left: 18px;\n}\n.rice + .optionlabel {\n padding-left: 0;\n}\n.section-script fieldset,\n.styleoption {\n text-align: left;\n}\n.section-style fieldset {\n width: 370px;\n}\n.section-script fieldset {\n width: 200px;\n}\n.suboptions {\n overflow: auto;\n position: absolute;\n top: 0;\n right: 0;\n bottom: 1.7em;\n left: 0;\n}\n.mAlign {\n height: 250px;\n vertical-align: middle;\n display: table-cell;\n}\n#save,\n.stylesettings {\n position: absolute;\n right: 10px;\n bottom: 0;\n}\n.section-style .suboptions {\n bottom: 0;\n}\n.section-container textarea {\n font-family: monospace;\n min-height: 350px;\n resize: vertical;\n width: 100%;\n}\n/* Hover Functionality */\n#mouseover {\n z-index: 33;\n position: fixed;\n max-width: 70%;\n}\n#mouseover:empty {\n display: none;\n}\n/* Mascot Tab */\n#mascot_hide {\n padding: 3px;\n position: absolute;\n top: 2px;\n right: 18px;\n}\n#mascot_hide .rice {\n float: left;\n}\n#mascot_hide > div {\n height: 0;\n text-align: right;\n overflow: hidden;\n}\n#mascot_hide:hover > div {\n height: auto;\n}\n#mascot_hide label {\n width: 100%;\n display: block;\n clear: both;\n text-decoration: none;\n}\n.mascots {\n padding: 0;\n text-align: center;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n.mascot,\n.mascotcontainer {\n overflow: hidden;\n}\n.mascot {\n position: relative;\n border: none;\n margin: 5px;\n padding: 0;\n width: 200px;\n display: inline-block;\n background-color: transparent;\n}\n.mascotcontainer {\n height: 250px;\n border: 0;\n margin: 0;\n max-height: 250px;\n cursor: pointer;\n bottom: 0;\n border-width: 0 1px 1px;\n border-style: solid;\n border-color: transparent;\n overflow: hidden;\n}\n.mascot img {\n max-width: 200px;\n}\n.mascotname,\n.mascotoptions {\n padding: 0;\n width: 100%;\n}\n.mascot .mascotoptions {\nopacity: 0;\n " + agent + "transition: opacity .3s linear;\n}\n.mascot:hover .mascotoptions {\n opacity: 1;\n}\n.mascotoptions {\n position: absolute;\n bottom: 0;\n right: 0;\n left: 0;\n}\n.mascotoptions a {\n display: inline-block;\n width: 33%;\n}\n#upload {\n position: absolute;\n width: 100px;\n left: 50%;\n margin-left: -50px;\n text-align: center;\n bottom: 0;\n}\n#mascots_batch {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Themes Tab */\n#themes h1 {\n position: absolute;\n right: 300px;\n bottom: 10px;\n margin: 0;\n " + agent + "transition: all .2s ease-in-out;\n opacity: 0;\n}\n#themes .selectedtheme h1 {\n right: 11px;\n opacity: 1;\n}\n#addthemes {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n.theme {\n margin: 1em;\n}\n/* Theme Editor */\n#themeConf {\n position: fixed;\n " + Style.sidebarLocation[1] + ": 2px;\n " + Style.sidebarLocation[0] + ": auto;\n top: 0;\n bottom: 0;\n width: 296px;\n z-index: 10;\n}\n#themebar input {\n width: 30%;\n}\n.option .color {\n width: 10%;\n border-left: none !important;\n color: transparent !important;\n}\n.option .colorfield {\n width: 90%;\n}\n.themevar textarea {\n min-width: 100%;\n max-width: 100%;\n height: 20em;\n resize: vertical;\n}\n/* Mascot Editor */\n#mascotConf {\n position: fixed;\n height: 17em;\n bottom: 0;\n left: 50%;\n width: 500px;\n margin-left: -250px;\n overflow: auto;\n z-index: 10;\n}\n#mascotConf .option,\n#mascotConf .optionlabel {\n " + Style.sizing + ": border-box;\n width: 50%;\n display: inline-block;\n vertical-align: middle;\n}\n#mascotConf .option input {\n width: 100%;\n}\n#close {\n position: absolute;\n left: 10px;\n bottom: 0;\n}\n/* Catalog */\n#content .navLinks,\n#info .navLinks,\n.btn-wrap {\n display: block;\n}\n.navLinks > .btn-wrap:not(:first-of-type)::before {\n content: ' - ';\n}\n.button {\n cursor: pointer;\n}\n#content .btn-wrap,\n#info .btn-wrap {\n display: inline-block;\n}\n#post-preview {\n position: absolute;\n z-index: 22;\n " + (_conf["Rounded Edges"] ? "border-radius: 3px;" : "") + "\n}\n#settings,\n#threads,\n#info .navLinks,\n#content .navLinks {\n text-align: center;\n}\n#threads .thread {\n vertical-align: top;\n display: inline-block;\n word-wrap: break-word;\n overflow: hidden;\n margin-top: 5px;\n padding: 5px 0 3px;\n text-align: center;\n}\n.extended-small .thread,\n.small .thread {\n width: 165px;\n max-height: 320px;\n}\n.small .teaser,\n.large .teaser {\n display: none;\n}\n.extended-large .thread,\n.large .thread {\n width: 270px;\n max-height: 410px;\n}\n.extended-small .thumb,\n.small .thumb {\n max-width: 150px;\n max-height: 150px;\n}\n.panel {\n position: fixed;\n top: 50% !important;\n left: 50%;\n " + agent + "transform: translate(-50%, -50%);\n}\n.icon::after {\n display: inline-block;\n float: right;\n width: 1em;\n cursor: pointer;\n}\n.helpIcon::after {\n content: '?';\n}\n.closeIcon::after {\n content: '×';\n}\n/* Front Page */\n#logo {\n text-align: center;\n}\n#doc {\n margin: 0 auto;\n width: 1000px;\n position: relative;\n}\n#boards .boxcontent {\n vertical-align: top;\n text-align: center;\n}\n#filter-container,\n#options-container {\n float: right;\n position: relative;\n}\n#optionssmenu {\n top: 100% !important;\n left: 0 !important;\n}\n#boards .column {\n " + Style.sizing + ": border-box;\n display: inline-block;\n width: 16em;\n text-align: left;\n vertical-align: top;\n}\n.bd ul,\n.boxcontent ul {\n vertical-align: top;\n padding: 0;\n}\n.right-box .boxcontent ul {\n padding: 0 10px;\n}\n.yuimenuitem,\n.boxcontent li {\n list-style-type: none;\n}\n.bd ul {\n margin: 0;\n}\n.yuimenuitem::before {\n content: \" [ ] \";\n font-family: monospace;\n}\n.yuimenuitem-checked::before {\n content: \" [x] \"\n}\n.yui-u {\n display: inline-block;\n vertical-align: top;\n width: 475px;\n margin: 10px;\n}\n#recent-images .boxcontent {\n text-align: center;\n}\n#ft {\n text-align: center;\n}\n#ft ul {\n padding: 0;\n}\n#ft li {\n list-style-type: none;\n display: inline-block;\n width: 100px;\n}\n#preview-tooltip-nws,\n#preview-tooltip-ws,\n#ft .fill,\n.clear-bug {\n display: none;\n}"; }, theme: function(theme) { var agent, background, backgroundC, bgColor, css, fileHeading, icons, replyHeading, _conf; @@ -13799,7 +13801,7 @@ }); }, mascots: function(section, mode) { - var batchmascots, categories, cb, header, keys, mascot, mascotEl, mascotHide, menu, name, option, parentdiv, suboptions, _i, _j, _k, _len, _len1, _len2, _ref; + var batchmascots, categories, cb, keys, mascot, mascotEl, mascotHide, menu, name, node, nodes, option, suboptions, _i, _j, _k, _l, _len, _len1, _len2, _len3, _len4, _m, _ref, _ref1, _ref2; categories = {}; menu = []; @@ -13807,9 +13809,6 @@ if (typeof mode !== 'string') { mode = 'default'; } - parentdiv = $.el("div", { - id: "mascotContainer" - }); suboptions = $.el("div", { className: "suboptions" }); @@ -13821,27 +13820,24 @@ keys = Object.keys(Mascots); keys.sort(); if (mode === 'default') { + nodes = {}; _ref = MascotTools.categories; for (_i = 0, _len = _ref.length; _i < _len; _i++) { name = _ref[_i]; + nodes[name] = []; categories[name] = $.el("div", { className: "mascots", - id: name + id: name, + innerHTML: "

" + name + "

" }); if (Conf["Hidden Categories"].contains(name)) { categories[name].hidden = true; } - header = $.el("h3", { - className: "mascotHeader", - textContent: name - }); menu.push(option = $.el("label", { name: name, innerHTML: "" + name })); - $.on($('input', option), 'change', Settings.cb.mascotCategory); - $.add(categories[name], header); - $.add(suboptions, categories[name]); + $.on($('input', option), 'change', cb.category); } for (_j = 0, _len1 = keys.length; _j < _len1; _j++) { name = keys[_j]; @@ -13850,34 +13846,37 @@ } mascot = Mascots[name]; mascotEl = $.el('div', { - className: 'mascot', + className: Conf[g.MASCOTSTRING].contains(name) ? 'mascot enabled' : 'mascot', id: name, innerHTML: "
" + (name.replace(/_/g, " ")) + "
" }); - if (Conf[g.MASCOTSTRING].contains(name)) { - $.addClass(mascotEl, 'enabled'); - } $.on($('.edit', mascotEl), 'click', cb.edit); $.on($('.delete', mascotEl), 'click', cb["delete"]); $.on($('.export', mascotEl), 'click', cb["export"]); $.on(mascotEl, 'click', cb.select); if (MascotTools.categories.contains(mascot.category)) { - $.add(categories[mascot.category], mascotEl); + nodes[mascot.category].push(mascotEl); } else { - $.add(categories[MascotTools.categories[0]], mascotEl); + nodes[MascotTools.categories[0]].push(mascotEl); } } + _ref1 = MascotTools.categories; + for (_k = 0, _len2 = _ref1.length; _k < _len2; _k++) { + name = _ref1[_k]; + $.add(categories[name], nodes[name]); + $.add(suboptions, categories[name]); + } $.add($('div', mascotHide), menu); batchmascots = $.el('div', { id: "mascots_batch", - innerHTML: "Clear All /Select All /Add Mascot /Import Mascot /Undelete Mascots /Get More Mascots! " + innerHTML: " Clear All\n/\nSelect All\n/\nAdd Mascot\n/\nImport Mascot\n/\nUndelete Mascots\n/\nGet More Mascots!" }); $.on($('#clear', batchmascots), 'click', function() { - var enabledMascots, _k, _len2; + var enabledMascots, _l, _len3; enabledMascots = JSON.parse(JSON.stringify(Conf[g.MASCOTSTRING])); - for (_k = 0, _len2 = enabledMascots.length; _k < _len2; _k++) { - name = enabledMascots[_k]; + for (_l = 0, _len3 = enabledMascots.length; _l < _len3; _l++) { + name = enabledMascots[_l]; $.rmClass($.id(name), 'enabled'); } return $.set(g.MASCOTSTRING, Conf[g.MASCOTSTRING] = []); @@ -13916,12 +13915,12 @@ return Settings.openSection.apply(mascots, ['restore']); }); } else { + nodes = []; categories = $.el("div", { - className: "mascots", - id: name + className: "mascots" }); - for (_k = 0, _len2 = keys.length; _k < _len2; _k++) { - name = keys[_k]; + for (_l = 0, _len3 = keys.length; _l < _len3; _l++) { + name = keys[_l]; if (!Conf["Deleted Mascots"].contains(name)) { continue; } @@ -13931,9 +13930,10 @@ id: name, innerHTML: "
" + (name.replace(/_/g, " ")) + "
" }); - $.on(mascotEl, 'click', Settings.cb.mascot.restore); - $.add(categories, mascotEl); + $.on(mascotEl, 'click', cb.restore); + nodes.push(mascotEl); } + $.add(categories, nodes); $.add(suboptions, categories); batchmascots = $.el('div', { id: "mascots_batch", @@ -13949,9 +13949,12 @@ return Settings.openSection.apply(mascots); }); } - $.add(parentdiv, [suboptions, batchmascots, mascotHide]); - Rice.nodes(parentdiv); - return $.add(section, parentdiv); + _ref2 = [suboptions, batchmascots, mascotHide]; + for (_m = 0, _len4 = _ref2.length; _m < _len4; _m++) { + node = _ref2[_m]; + Rice.nodes(node); + } + return $.add(section, [suboptions, batchmascots, mascotHide]); }, cb: { mascot: { diff --git a/src/General/Settings.coffee b/src/General/Settings.coffee index e6203514d..5dc8875e6 100644 --- a/src/General/Settings.coffee +++ b/src/General/Settings.coffee @@ -543,7 +543,7 @@ Settings = keys.sort() cb = Settings.cb.theme - + if mode is "default" for name in keys @@ -640,10 +640,10 @@ Settings = $.on $('#tUndelete', div), 'click', -> $.rm $.id "themeContainer" - themes = + themes = open: Settings.themes hyphenatedTitle: 'themes' - + Settings.openSection.apply themes, ['undelete'] else @@ -684,7 +684,7 @@ Settings = innerHTML: "Return" $.on $('a', div), 'click', -> - themes = + themes = open: Settings.themes hyphenatedTitle: 'themes' @@ -722,9 +722,6 @@ Settings = if typeof mode isnt 'string' mode = 'default' - parentdiv = $.el "div", - id: "mascotContainer" - suboptions = $.el "div", className: "suboptions" @@ -738,64 +735,52 @@ Settings = if mode is 'default' # Create a keyed Unordered List Element and hide option for each mascot category. + nodes = {} for name in MascotTools.categories + nodes[name] = [] categories[name] = $.el "div", className: "mascots" id: name + innerHTML: "

#{name}

" if Conf["Hidden Categories"].contains name categories[name].hidden = true - header = $.el "h3", - className: "mascotHeader" - textContent: name - menu.push option = $.el "label", name: name innerHTML: "#{name}" - $.on $('input', option), 'change', Settings.cb.mascotCategory - - $.add categories[name], header - $.add suboptions, categories[name] + $.on $('input', option), 'change', cb.category for name in keys continue if Conf["Deleted Mascots"].contains name mascot = Mascots[name] mascotEl = $.el 'div', - className: 'mascot' + className: if Conf[g.MASCOTSTRING].contains name then 'mascot enabled' else 'mascot' id: name - innerHTML: " -
#{name.replace /_/g, " "}
-
-" - - if Conf[g.MASCOTSTRING].contains name - $.addClass mascotEl, 'enabled' + innerHTML: "<%= grunt.file.read('src/General/html/Settings/Mascot.html') %>" $.on $('.edit', mascotEl), 'click', cb.edit $.on $('.delete', mascotEl), 'click', cb.delete $.on $('.export', mascotEl), 'click', cb.export - $.on mascotEl, 'click', cb.select + + $.on mascotEl, 'click', cb.select if MascotTools.categories.contains mascot.category - $.add categories[mascot.category], mascotEl + nodes[mascot.category].push mascotEl else - $.add categories[MascotTools.categories[0]], mascotEl + nodes[MascotTools.categories[0]].push mascotEl + + for name in MascotTools.categories + $.add categories[name], nodes[name] + $.add suboptions, categories[name] $.add $('div', mascotHide), menu batchmascots = $.el 'div', id: "mascots_batch" - innerHTML: " -Clear All / -Select All / -Add Mascot / -Import Mascot / -Undelete Mascots / -Get More Mascots! - " + innerHTML: """<%= grunt.file.read('src/General/html/Settings/Batch-Mascot.html') %>""" $.on $('#clear', batchmascots), 'click', -> enabledMascots = JSON.parse(JSON.stringify(Conf[g.MASCOTSTRING])) @@ -824,15 +809,15 @@ Settings = unless Conf["Deleted Mascots"].length > 0 alert "No mascots have been deleted." return - mascots = + mascots = open: Settings.mascots hyphenatedTitle: 'mascots' Settings.openSection.apply mascots, ['restore'] else + nodes = [] categories = $.el "div", className: "mascots" - id: name for name in keys continue unless Conf["Deleted Mascots"].contains name @@ -845,9 +830,11 @@ Settings =
" - $.on mascotEl, 'click', Settings.cb.mascot.restore + $.on mascotEl, 'click', cb.restore - $.add categories, mascotEl + nodes.push mascotEl + + $.add categories, nodes $.add suboptions, categories @@ -856,30 +843,29 @@ Settings = innerHTML: "Return" $.on $('#return', batchmascots), 'click', -> - mascots = + mascots = open: Settings.mascots hyphenatedTitle: 'mascots' Settings.openSection.apply mascots - $.add parentdiv, [suboptions, batchmascots, mascotHide] + for node in [suboptions, batchmascots, mascotHide] + Rice.nodes node - Rice.nodes parentdiv - - $.add section, parentdiv + $.add section, [suboptions, batchmascots, mascotHide] cb: mascot: category: -> if $.id(@name).hidden = @checked Conf["Hidden Categories"].push @name - + # Gather all names of enabled mascots in the hidden category in every context it could be enabled. for type in ["Enabled Mascots", "Enabled Mascots sfw", "Enabled Mascots nsfw"] setting = Conf[type] i = setting.length - + test = type is g.MASCOTSTRING - + while i-- name = setting[i] continue unless Mascots[name].category is @name @@ -887,17 +873,17 @@ Settings = continue unless test $.rmClass $.id(name), 'enabled' $.set type, setting - + else Conf["Hidden Categories"].remove @name - + $.set "Hidden Categories", Conf["Hidden Categories"] - + edit: (e) -> e.stopPropagation() MascotTools.dialog @name Settings.close() - + delete: (e) -> e.stopPropagation() if confirm "Are you sure you want to delete \"#{@name}\"?" @@ -909,24 +895,24 @@ Settings = Conf["Deleted Mascots"].push @name $.set "Deleted Mascots", Conf["Deleted Mascots"] $.rm $.id @name - + export: (e) -> e.stopPropagation() exportMascot = Mascots[@name] exportMascot['Mascot'] = @name exportedMascot = "data:application/json," + encodeURIComponent(JSON.stringify(exportMascot)) - + if window.open exportedMascot, "_blank" return else if confirm "Your popup blocker is preventing Appchan X from exporting this theme. Would you like to open the exported theme in this window?" window.location exportedMascot - + restore: -> if confirm "Are you sure you want to restore \"#{@id}\"?" Conf["Deleted Mascots"].remove @id $.set "Deleted Mascots", Conf["Deleted Mascots"] $.rm @ - + select: -> if Conf[g.MASCOTSTRING].remove @id if Conf['mascot'] is @id @@ -936,13 +922,13 @@ Settings = MascotTools.init @id $.toggleClass @, 'enabled' $.set g.MASCOTSTRING, Conf[g.MASCOTSTRING] - - + + theme: select: -> if currentTheme = $.id(Conf['theme']) $.rmClass currentTheme, 'selectedtheme' - + if Conf["NSFW/SFW Themes"] $.set "theme_#{g.TYPE}", @id else diff --git a/src/General/css/layout.css b/src/General/css/layout.css index ea88e1575..8ba39a096 100644 --- a/src/General/css/layout.css +++ b/src/General/css/layout.css @@ -1600,9 +1600,7 @@ article li { .section-script fieldset { width: 200px; } -.suboptions, -#mascotcontent, -#themecontent { +.suboptions { overflow: auto; position: absolute; top: 0; @@ -1615,9 +1613,6 @@ article li { vertical-align: middle; display: table-cell; } -#themecontent { - top: 1.7em; -} #save, .stylesettings { position: absolute; @@ -1747,9 +1742,6 @@ opacity: 0; right: 11px; opacity: 1; } -#themeContainer { - margin-bottom: 3px; -} #addthemes { position: absolute; left: 10px; diff --git a/src/General/html/Settings/Batch-Mascot.html b/src/General/html/Settings/Batch-Mascot.html new file mode 100644 index 000000000..c52096993 --- /dev/null +++ b/src/General/html/Settings/Batch-Mascot.html @@ -0,0 +1,11 @@ + Clear All + / + Select All + / + Add Mascot + / + Import Mascot + / + Undelete Mascots + / + Get More Mascots! \ No newline at end of file diff --git a/src/General/html/Settings/Mascot.html b/src/General/html/Settings/Mascot.html new file mode 100644 index 000000000..42b54bfb8 --- /dev/null +++ b/src/General/html/Settings/Mascot.html @@ -0,0 +1,3 @@ +
#{name.replace /_/g, " "}
+
+ \ No newline at end of file diff --git a/src/Theming/Mascots.coffee b/src/Theming/Mascots.coffee index f2304f8ab..05c9d97e4 100644 --- a/src/Theming/Mascots.coffee +++ b/src/Theming/Mascots.coffee @@ -189,6 +189,7 @@ MascotTools = Close
" + nodes = [] for name, item of layout switch item[2] @@ -270,7 +271,8 @@ MascotTools = MascotTools.addMascot editMascot Style.addStyle() - $.add $("#mascotcontent", dialog), div + nodes.push div + $.add $("#mascotcontent", dialog), nodes $.on $('#save > a', dialog), 'click', -> MascotTools.save editMascot