Changeset 3858:ebcc8a63a4e1 for admin
- Timestamp:
- 09/04/18 11:14:41 (7 years ago)
- Branch:
- default
- Parents:
- 3857:f3946d839070 (diff), 3855:08b090767191 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent. - Location:
- admin
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
admin/js/common.js
r3843 r3858 140 140 $(ctarget).click(function(e) { 141 141 if (p.user_pref && set_user_pref) { 142 if (p.hide ^ p.reverse_user_pref) { 143 jQuery.post('services.php', { 144 'f': 'setSectionFold', 145 'section': p.user_pref, 146 'value': 1, 147 xd_check: dotclear.nonce 148 }, function() {}); 149 } else { 150 jQuery.post('services.php', { 151 'f': 'setSectionFold', 152 'section': p.user_pref, 153 'value': 0, 154 xd_check: dotclear.nonce 155 }, function() {}); 156 } 142 jQuery.post('services.php', { 143 'f': 'setSectionFold', 144 'section': p.user_pref, 145 'value': (p.hide ^ p.reverse_user_pref ? 1 : 0), 146 xd_check: dotclear.nonce 147 }, function() {}); 157 148 jQuery.cookie(p.user_pref, '', { 158 149 expires: -1 … … 169 160 (function($) { 170 161 $.expandContent = function(opts) { 171 var defaults = {};172 $.expandContent.options = $.extend({}, defaults, opts);173 162 if (opts == undefined || opts.callback == undefined || !$.isFunction(opts.callback)) { 174 163 return; 175 164 } 176 165 if (opts.line != undefined) { 177 multipleExpander(opts.line, opts.lines );166 multipleExpander(opts.line, opts.lines, opts.callback); 178 167 } 179 168 opts.lines.each(function() { 180 singleExpander(this );181 }); 182 }; 183 var singleExpander = function singleExpander(line ) {169 singleExpander(this, opts.callback); 170 }); 171 }; 172 var singleExpander = function singleExpander(line, callback) { 184 173 $('<button type="button" class="details-cmd" aria-label="' + dotclear.img_plus_alt + '">' + dotclear.img_plus_txt + '</button>').click(function (e) { 185 174 toggleArrow(this); 186 $.expandContent.options.callback.call(this,line);175 callback(line); 187 176 e.preventDefault(); 188 177 }).prependTo($(line).children().get(0)); // first td 189 178 }; 190 var multipleExpander = function multipleExpander(line, lines ) {179 var multipleExpander = function multipleExpander(line, lines, callback) { 191 180 $('<button type="button" class="details-cmd" aria-label="' + dotclear.img_plus_alt + '">' + dotclear.img_plus_txt + '</button>').click(function (e) { 192 var that = this;193 181 var action = toggleArrow(this); 194 182 lines.each(function() { 195 183 toggleArrow(this.firstChild.firstChild, action); 196 $.expandContent.options.callback.call(that,this, action);184 callback(this, action); 197 185 }); 198 186 e.preventDefault(); … … 311 299 enterKeyInForm: function(frm_id, ok_id, cancel_id) { 312 300 $(frm_id + ':not(' + cancel_id + ')').keyup(function(e) { 313 if ( e.key == 'Enter') {301 if ((e.key == 'Enter') && ($(ok_id).prop('disabled') !== true)) { 314 302 e.preventDefault(); 315 303 e.stopPropagation(); … … 445 433 return true; 446 434 }); 435 }, 436 outgoingLinks: function(target) { 437 $(target).filter(function() { 438 return ((this.hostname && this.hostname != location.hostname && !$(this).hasClass('modal') && !$(this).hasClass('modal-image')) || $(this).hasClass('outgoing')); 439 }).each(function() { 440 $(this).prop('title', $(this).prop('title') + ' (' + dotclear.msg.new_window + ')'); 441 if (!$(this).hasClass('outgoing')) { 442 $(this).append(' <img class="outgoing-js" src="images/outgoing-link.svg" alt=""/>'); 443 } 444 }).click(function(e) { 445 e.preventDefault(); 446 window.open($(this).attr('href')); 447 }); 447 448 } 448 449 }; … … 460 461 }); 461 462 // manage outgoing links 462 $('a').filter(function() { 463 return ((this.hostname && this.hostname != location.hostname && !$(this).hasClass('modal') && !$(this).hasClass('modal-image')) || $(this).hasClass('outgoing')); 464 }).each(function() { 465 $(this).prop('title', $(this).prop('title') + ' (' + dotclear.msg.new_window + ')'); 466 if (!$(this).hasClass('outgoing')) { 467 $(this).append(' <img class="outgoing-js" src="images/outgoing-link.svg" alt=""/>'); 468 } 469 }).click(function(e) { 470 e.preventDefault(); 471 window.open($(this).attr('href')); 472 }); 463 dotclear.outgoingLinks('a'); 473 464 // Popups: dealing with Escape key fired 474 465 $('#dotclear-admin.popup').keyup(function(e) { -
admin/style/default-dark.css
r3853 r3858 229 229 /* Typographie */ 230 230 :root { 231 --html-font-size: 62.5%; } 231 --html-font-size: 62.5%; 232 --body-color: #dcdee0; 233 --body-background: #272b30; } 232 234 233 235 html { … … 1081 1083 margin-bottom: .3em; } 1082 1084 1085 input[type=color] { 1086 width: 4em; 1087 height: 3em; } 1088 1083 1089 optgroup { 1084 1090 font-weight: bold; … … 1583 1589 padding: 0; 1584 1590 overflow: hidden; 1585 position: absolute;1586 top: 3em;1587 left: 0;1588 1591 background: #a2cbe9; 1589 width: 100%; 1590 z-index: 100; } 1592 width: 100%; } 1591 1593 #prelude li { 1592 1594 list-style-type: none; … … 2111 2113 #dashboard-main { 2112 2114 text-align: center; } 2115 #dashboard-main > *:last-child { 2116 margin-bottom: 1em; } 2113 2117 2114 2118 /* raccourcis */ 2115 2119 #icons { 2120 margin: 1em auto 2em; 2116 2121 display: flex; 2117 2122 flex-wrap: wrap; … … 2150 2155 /* billet rapide */ 2151 2156 #quick { 2157 max-width: 72em; 2158 margin: 1em auto 2em; 2152 2159 padding: 1em; 2153 max-width: 72em;2154 margin: 0 auto;2155 2160 background: #323334; 2156 2161 border: 1px solid #dbdcdd; … … 2165 2170 padding: .2em 1em .1em 24px; 2166 2171 color: #323334; } 2167 #quick #new_cat, 2168 #quick .q-cat, 2169 #quick .q-cat label { 2172 #quick #new_cat, #quick .q-cat, #quick .q-cat label { 2170 2173 display: inline-block; 2171 2174 vertical-align: top; … … 2179 2182 /* modules additionnels */ 2180 2183 #dashboard-boxes { 2181 margin: 1em auto 1em; 2182 padding-top: 2em; 2184 margin: 1em auto 2em; 2183 2185 display: flex; 2184 2186 flex-wrap: wrap; … … 2192 2194 text-align: left; } 2193 2195 2194 .db-items, 2195 .db-contents { 2196 .db-items, .db-contents { 2196 2197 display: flex; 2197 2198 flex-wrap: wrap; 2198 2199 justify-content: center; 2199 2200 flex: 1 1 auto; } 2200 .db-items img, 2201 .db-contents img { 2201 .db-items img, .db-contents img { 2202 2202 vertical-align: middle; } 2203 .db-items ul, 2204 .db-contents ul { 2203 .db-items ul, .db-contents ul { 2205 2204 display: block; 2206 2205 padding-left: 1.5em; 2207 2206 list-style: square; } 2208 .db-items li, 2209 .db-contents li { 2207 .db-items li, .db-contents li { 2210 2208 margin: 0.25em 0 0 0; } 2211 2209 … … 3164 3162 3165 3163 .offline { 3166 color: #86888c; } 3164 color: #86888c; 3165 background: #323334; } 3167 3166 3168 3167 /* caché pour tout le monde */ … … 3193 3192 3194 3193 /* ---------------------------------------------- Couleurs ajoutées via javascript 3194 3195 /* Sortable (jQuery UI) */ 3196 .sortable-area { 3197 border: 1px dashed currentColor; 3198 background-color: #4c4d4f; } 3199 3195 3200 /* color-picker.js */ 3196 3201 .color-color-picker { -
admin/style/default.css
r3853 r3858 229 229 /* Typographie */ 230 230 :root { 231 --html-font-size: 62.5%; } 231 --html-font-size: 62.5%; 232 --body-color: #323232; 233 --body-background: #fff; } 232 234 233 235 html { … … 1081 1083 margin-bottom: .3em; } 1082 1084 1085 input[type=color] { 1086 width: 4em; 1087 height: 3em; } 1088 1083 1089 optgroup { 1084 1090 font-weight: bold; … … 1583 1589 padding: 0; 1584 1590 overflow: hidden; 1585 position: absolute;1586 top: 3em;1587 left: 0;1588 1591 background: #a2cbe9; 1589 width: 100%; 1590 z-index: 100; } 1592 width: 100%; } 1591 1593 #prelude li { 1592 1594 list-style-type: none; … … 2111 2113 #dashboard-main { 2112 2114 text-align: center; } 2115 #dashboard-main > *:last-child { 2116 margin-bottom: 1em; } 2113 2117 2114 2118 /* raccourcis */ 2115 2119 #icons { 2120 margin: 1em auto 2em; 2116 2121 display: flex; 2117 2122 flex-wrap: wrap; … … 2150 2155 /* billet rapide */ 2151 2156 #quick { 2157 max-width: 72em; 2158 margin: 1em auto 2em; 2152 2159 padding: 1em; 2153 max-width: 72em;2154 margin: 0 auto;2155 2160 background: #f3f3f3; 2156 2161 border: 1px solid #dbdbdb; … … 2165 2170 padding: .2em 1em .1em 24px; 2166 2171 color: #323232; } 2167 #quick #new_cat, 2168 #quick .q-cat, 2169 #quick .q-cat label { 2172 #quick #new_cat, #quick .q-cat, #quick .q-cat label { 2170 2173 display: inline-block; 2171 2174 vertical-align: top; … … 2179 2182 /* modules additionnels */ 2180 2183 #dashboard-boxes { 2181 margin: 1em auto 1em; 2182 padding-top: 2em; 2184 margin: 1em auto 2em; 2183 2185 display: flex; 2184 2186 flex-wrap: wrap; … … 2192 2194 text-align: left; } 2193 2195 2194 .db-items, 2195 .db-contents { 2196 .db-items, .db-contents { 2196 2197 display: flex; 2197 2198 flex-wrap: wrap; 2198 2199 justify-content: center; 2199 2200 flex: 1 1 auto; } 2200 .db-items img, 2201 .db-contents img { 2201 .db-items img, .db-contents img { 2202 2202 vertical-align: middle; } 2203 .db-items ul, 2204 .db-contents ul { 2203 .db-items ul, .db-contents ul { 2205 2204 display: block; 2206 2205 padding-left: 1.5em; 2207 2206 list-style: square; } 2208 .db-items li, 2209 .db-contents li { 2207 .db-items li, .db-contents li { 2210 2208 margin: 0.25em 0 0 0; } 2211 2209 … … 3164 3162 3165 3163 .offline { 3166 color: #676e78; } 3164 color: #676e78; 3165 background: #f3f3f3; } 3167 3166 3168 3167 /* caché pour tout le monde */ … … 3193 3192 3194 3193 /* ---------------------------------------------- Couleurs ajoutées via javascript 3194 3195 /* Sortable (jQuery UI) */ 3196 .sortable-area { 3197 border: 1px dashed currentColor; 3198 background-color: #f3f3f3; } 3199 3195 3200 /* color-picker.js */ 3196 3201 .color-color-picker {
Note: See TracChangeset
for help on using the changeset viewer.