Changeset 51319
- Timestamp:
- 07/02/2021 07:05:46 PM (3 years ago)
- Location:
- branches/5.8
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/5.8
-
branches/5.8/src/wp-content/themes/twentytwentyone/classes/class-twenty-twenty-one-custom-colors.php
r51236 r51319 15 15 /** 16 16 * Instantiate the object. 17 *18 * @access public19 17 * 20 18 * @since Twenty Twenty-One 1.0 … … 35 33 * Determine the luminance of the given color and then return #fff or #000 so that the text is always readable. 36 34 * 37 * @ access public35 * @since Twenty Twenty-One 1.0 38 36 * 39 37 * @param string $background_color The background color. 40 *41 * @since Twenty Twenty-One 1.042 *43 38 * @return string (hex color) 44 39 */ … … 54 49 * The code below needs to be updated, because the colors are no longer theme mods. 55 50 * 56 * @access public57 *58 51 * @since Twenty Twenty-One 1.0 59 52 * 60 53 * @param string|null $context Can be "editor" or null. 61 *62 54 * @return string 63 55 */ … … 88 80 * Customizer & frontend custom color variables. 89 81 * 90 * @access public91 *92 82 * @since Twenty Twenty-One 1.0 93 83 * … … 102 92 /** 103 93 * Editor custom color variables. 104 *105 * @access public106 94 * 107 95 * @since Twenty Twenty-One 1.0 … … 128 116 * @static 129 117 * 130 * @access public131 *132 118 * @since Twenty Twenty-One 1.0 133 119 * 134 120 * @param string $hex The HEX color. 135 *136 121 * @return int Returns a number (0-255). 137 122 */ … … 159 144 * Adds a class to <body> if the background-color is dark. 160 145 * 161 * @access public162 *163 146 * @since Twenty Twenty-One 1.0 164 147 * 165 148 * @param array $classes The existing body classes. 166 *167 149 * @return array 168 150 */ -
branches/5.8/src/wp-content/themes/twentytwentyone/classes/class-twenty-twenty-one-customize-color-control.php
r51236 r51319 28 28 * Colorpicker palette 29 29 * 30 * @access public31 *32 30 * @since Twenty Twenty-One 1.0 33 31 * … … 38 36 /** 39 37 * Enqueue control related scripts/styles. 40 *41 * @access public42 38 * 43 39 * @since Twenty Twenty-One 1.0 … … 61 57 * Refresh the parameters passed to the JavaScript via JSON. 62 58 * 63 * @access public64 *65 59 * @since Twenty Twenty-One 1.0 66 60 * -
branches/5.8/src/wp-content/themes/twentytwentyone/classes/class-twenty-twenty-one-customize-notice-control.php
r49826 r51319 30 30 * This simply prints the notice we need. 31 31 * 32 * @access public33 *34 32 * @since Twenty Twenty-One 1.0 35 33 * -
branches/5.8/src/wp-content/themes/twentytwentyone/classes/class-twenty-twenty-one-customize.php
r49826 r51319 19 19 * Constructor. Instantiate the object. 20 20 * 21 * @access public22 *23 21 * @since Twenty Twenty-One 1.0 24 22 */ … … 30 28 * Register customizer options. 31 29 * 32 * @access public33 *34 30 * @since Twenty Twenty-One 1.0 35 31 * 36 32 * @param WP_Customize_Manager $wp_customize Theme Customizer object. 37 *38 33 * @return void 39 34 */ … … 152 147 * Sanitize boolean for checkbox. 153 148 * 154 * @access public155 *156 149 * @since Twenty Twenty-One 1.0 157 150 * 158 151 * @param bool $checked Whether or not a box is checked. 159 *160 152 * @return bool 161 153 */ … … 166 158 /** 167 159 * Render the site title for the selective refresh partial. 168 *169 * @access public170 160 * 171 161 * @since Twenty Twenty-One 1.0 … … 180 170 * Render the site tagline for the selective refresh partial. 181 171 * 182 * @access public183 *184 172 * @since Twenty Twenty-One 1.0 185 173 * -
branches/5.8/src/wp-content/themes/twentytwentyone/classes/class-twenty-twenty-one-dark-mode.php
r51246 r51319 16 16 * Instantiate the object. 17 17 * 18 * @access public19 *20 18 * @since Twenty Twenty-One 1.0 21 19 */ … … 49 47 /** 50 48 * Editor custom color variables & scripts. 51 *52 * @access public53 49 * 54 50 * @since Twenty Twenty-One 1.0 … … 89 85 * Enqueue scripts and styles. 90 86 * 91 * @access public92 *93 87 * @since Twenty Twenty-One 1.0 94 88 * … … 108 102 /** 109 103 * Enqueue scripts for the customizer. 110 *111 * @access public112 104 * 113 105 * @since Twenty Twenty-One 1.0 … … 131 123 * Register customizer options. 132 124 * 133 * @access public134 *135 125 * @since Twenty Twenty-One 1.0 136 126 * 137 127 * @param WP_Customize_Manager $wp_customize Theme Customizer object. 138 *139 128 * @return void 140 129 */ … … 223 212 * Calculate classes for the main <html> element. 224 213 * 225 * @access public226 *227 214 * @since Twenty Twenty-One 1.0 228 215 * 229 216 * @param string $classes The classes for <html> element. 230 *231 217 * @return string 232 218 */ … … 248 234 * Adds a class to the <body> element in the editor to accommodate dark-mode. 249 235 * 250 * @access public251 *252 236 * @since Twenty Twenty-One 1.0 253 237 * 254 238 * @param string $classes The admin body-classes. 255 *256 239 * @return string 257 240 */ … … 280 263 /** 281 264 * Determine if we want to print the dark-mode switch or not. 282 *283 * @access public284 265 * 285 266 * @since Twenty Twenty-One 1.0 … … 299 280 * Add night/day switch. 300 281 * 301 * @access public302 *303 282 * @since Twenty Twenty-One 1.0 304 283 * … … 318 297 * Inspired from https://codepen.io/aaroniker/pen/KGpXZo (MIT-licensed) 319 298 * 320 * @access public321 *322 299 * @since Twenty Twenty-One 1.0 323 300 * 324 301 * @param array $attrs The attributes to add to our <button> element. 325 *326 302 * @return void 327 303 */ … … 379 355 * Print the dark-mode switch script. 380 356 * 381 * @access public382 *383 357 * @since Twenty Twenty-One 1.0 384 358 * … … 394 368 * Adds information to the privacy policy. 395 369 * 396 * @access public397 *398 370 * @since Twenty Twenty-One 1.0 399 371 * -
branches/5.8/src/wp-content/themes/twentytwentyone/classes/class-twenty-twenty-one-svg-icons.php
r49826 r51319 24 24 /** 25 25 * User Interface icons – svg sources. 26 *27 * @access protected28 26 * 29 27 * @since Twenty Twenty-One 1.0 … … 42 40 /** 43 41 * Social Icons – svg sources. 44 *45 * @access protected46 42 * 47 43 * @since Twenty Twenty-One 1.0 … … 149 145 * @static 150 146 * 151 * @access public 152 * 153 * @since Twenty Twenty-One 1.0 154 * 155 * @param string $group the icon group. 156 * @param string $icon The icon. 157 * @param int $size The icon-size in pixels. 158 * 147 * @since Twenty Twenty-One 1.0 148 * 149 * @param string $group The icon group. 150 * @param string $icon The icon. 151 * @param int $size The icon-size in pixels. 159 152 * @return string 160 153 */ … … 197 190 * @static 198 191 * 199 * @access public 200 * 201 * @since Twenty Twenty-One 1.0 202 * 203 * @param string $uri Social link. 192 * @since Twenty Twenty-One 1.0 193 * 194 * @param string $uri Social link. 204 195 * @param int $size The icon-size in pixels. 205 *206 196 * @return string|null 207 197 */ -
branches/5.8/src/wp-content/themes/twentytwentyone/inc/custom-css.php
r49826 r51319 14 14 * 15 15 * @param string $selector The CSS selector. 16 * @param string $style The CSS style. 17 * @param string $value The CSS value. 18 * @param string $prefix The CSS prefix. 19 * @param string $suffix The CSS suffix. 20 * @param bool $echo Echo the styles. 21 * 16 * @param string $style The CSS style. 17 * @param string $value The CSS value. 18 * @param string $prefix The CSS prefix. 19 * @param string $suffix The CSS suffix. 20 * @param bool $echo Echo the styles. 22 21 * @return string 23 22 */ … … 32 31 33 32 if ( $echo ) { 34 /* *33 /* 35 34 * Note to reviewers: $css contains auto-generated CSS. 36 35 * It is included inside <style> tags and can only be interpreted as CSS on the browser. -
branches/5.8/src/wp-content/themes/twentytwentyone/inc/menu-functions.php
r49826 r51319 23 23 * @param int $depth Depth. 24 24 * @param object $args Nav menu args. 25 *26 25 * @return string Nav menu item start element. 27 26 */ … … 45 44 * @since Twenty Twenty-One 1.0 46 45 * 47 * @param string $uri Social link.46 * @param string $uri Social link. 48 47 * @param int $size The icon size in pixels. 49 *50 48 * @return string 51 49 */ … … 85 83 * @param WP_Post $item Menu item data object. 86 84 * @param int $depth Depth of menu item. Used for padding. 87 *88 85 * @return stdClass 89 86 */ -
branches/5.8/src/wp-content/themes/twentytwentyone/inc/template-functions.php
r50841 r51319 14 14 * 15 15 * @param array $classes Classes for the body element. 16 *17 16 * @return array 18 17 */ … … 45 44 * 46 45 * @param array $classes An array of CSS classes. 47 *48 46 * @return array 49 47 */ … … 87 85 * 88 86 * @param array $defaults The form defaults. 89 *90 87 * @return array 91 88 */ … … 168 165 * 169 166 * @param string $title The title. 170 *171 167 * @return string 172 168 */ … … 183 179 * 184 180 * @param string $group The icon group. 185 * @param string $icon The icon. 186 * @param int $size The icon size in pixels. 187 * 181 * @param string $icon The icon. 182 * @param int $size The icon size in pixels. 188 183 * @return string 189 184 */ … … 196 191 * 197 192 * @param string $calendar_output The generated HTML of the calendar. 198 *199 193 * @return string 200 194 */ … … 212 206 * 213 207 * @param string $type Whether to return CSS for the "front-end", "block-editor" or "classic-editor". 214 *215 208 * @return string 216 209 */ … … 329 322 * Example: `core/image`, `core-embed/*`. 330 323 * @param string|null $content The content to search in. Use null for get_the_content(). 331 * @param int $instances How many instances of the block will be printed (max). Defaults to 1. 332 * 324 * @param int $instances How many instances of the block will be printed (max). Default 1. 333 325 * @return bool Returns true if a block was located & printed, otherwise false. 334 326 */ … … 416 408 * @param string|array $size Requested size. Image size or array of width and height values 417 409 * (in that order). Default 'thumbnail'. 418 *419 410 * @return array 420 411 */
Note: See TracChangeset
for help on using the changeset viewer.