Changeset 44314
- Timestamp:
- 12/18/2018 11:24:07 PM (6 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:mergeinfo changed
/branches/5.0 merged: 44231
- Property svn:mergeinfo changed
-
trunk/src/wp-includes/script-loader.php
r44308 r44314 1922 1922 $styles->add( 'open-sans', $open_sans_font_url ); // No longer used in core as of 4.6 1923 1923 1924 // Packages styles 1925 $fonts_url = ''; 1926 1927 /* 1928 * Translators: Use this to specify the proper Google Font name and variants 1929 * to load that is supported by your language. Do not translate. 1930 * Set to 'off' to disable loading. 1931 */ 1932 $font_family = _x( 'Noto Serif:400,400i,700,700i', 'Google Font Name and Variants' ); 1933 if ( 'off' !== $font_family ) { 1934 $fonts_url = 'https://fonts.googleapis.com/css?family=' . urlencode( $font_family ); 1935 } 1936 $styles->add( 'wp-editor-font', $fonts_url ); 1937 1938 $styles->add( 'wp-block-library-theme', "/wp-includes/css/dist/block-library/theme$suffix.css" ); 1939 1940 $styles->add( 1941 'wp-edit-blocks', 1942 "/wp-includes/css/dist/block-library/editor$suffix.css", 1943 array( 1944 'wp-components', 1945 'wp-editor', 1946 'wp-block-library', 1947 // Always include visual styles so the editor never appears broken. 1948 'wp-block-library-theme', 1949 ) 1950 ); 1951 1952 $package_styles = array( 1953 'block-library' => array(), 1954 'components' => array(), 1955 'edit-post' => array( 'wp-components', 'wp-editor', 'wp-edit-blocks', 'wp-block-library', 'wp-nux' ), 1956 'editor' => array( 'wp-components', 'wp-editor-font', 'wp-nux' ), 1957 'format-library' => array(), 1958 'list-reusable-blocks' => array( 'wp-components' ), 1959 'nux' => array( 'wp-components' ), 1960 ); 1961 1962 foreach ( $package_styles as $package => $dependencies ) { 1963 $handle = 'wp-' . $package; 1964 $path = "/wp-includes/css/dist/$package/style$suffix.css"; 1965 1966 $styles->add( $handle, $path, $dependencies ); 1967 } 1968 1924 1969 // RTL CSS 1925 1970 $rtl_styles = array( 1926 // wp-admin1971 // Admin CSS 1927 1972 'common', 1928 1973 'forms', … … 1947 1992 'ie', 1948 1993 'login', 1949 // wp-includes1994 // Includes CSS 1950 1995 'buttons', 1951 1996 'admin-bar', … … 1955 2000 'wp-pointer', 1956 2001 'wp-jquery-ui-dialog', 1957 // deprecated 2002 // Package styles 2003 'wp-block-library-theme', 2004 'wp-edit-blocks', 2005 'wp-block-library', 2006 'wp-components', 2007 'wp-edit-post', 2008 'wp-editor', 2009 'wp-format-library', 2010 'wp-list-reusable-blocks', 2011 'wp-nux', 2012 // Deprecated CSS 1958 2013 'deprecated-media', 1959 2014 'farbtastic', … … 1965 2020 $styles->add_data( $rtl_style, 'suffix', $suffix ); 1966 2021 } 1967 }1968 1969 // Packages styles1970 $fonts_url = '';1971 1972 /*1973 * Translators: Use this to specify the proper Google Font name and variants1974 * to load that is supported by your language. Do not translate.1975 * Set to 'off' to disable loading.1976 */1977 $font_family = _x( 'Noto Serif:400,400i,700,700i', 'Google Font Name and Variants' );1978 if ( 'off' !== $font_family ) {1979 $fonts_url = 'https://fonts.googleapis.com/css?family=' . urlencode( $font_family );1980 }1981 $styles->add( 'wp-editor-font', $fonts_url );1982 1983 $styles->add( 'wp-block-library-theme', "/wp-includes/css/dist/block-library/theme$suffix.css" );1984 $styles->add_data( 'wp-block-library-theme', 'rtl', 'replace' );1985 1986 $styles->add(1987 'wp-edit-blocks',1988 "/wp-includes/css/dist/block-library/editor$suffix.css",1989 array(1990 'wp-components',1991 'wp-editor',1992 'wp-block-library',1993 // Always include visual styles so the editor never appears broken.1994 'wp-block-library-theme',1995 )1996 );1997 $styles->add_data( 'wp-edit-blocks', 'rtl', 'replace' );1998 1999 $package_styles = array(2000 'block-library' => array(),2001 'components' => array(),2002 'edit-post' => array( 'wp-components', 'wp-editor', 'wp-edit-blocks', 'wp-block-library', 'wp-nux' ),2003 'editor' => array( 'wp-components', 'wp-editor-font', 'wp-nux' ),2004 'format-library' => array(),2005 'list-reusable-blocks' => array( 'wp-components' ),2006 'nux' => array( 'wp-components' ),2007 );2008 2009 foreach ( $package_styles as $package => $dependencies ) {2010 $handle = 'wp-' . $package;2011 $path = "/wp-includes/css/dist/$package/style$suffix.css";2012 2013 $styles->add( $handle, $path, $dependencies );2014 $styles->add_data( $handle, 'rtl', 'replace' );2015 2022 } 2016 2023 }
Note: See TracChangeset
for help on using the changeset viewer.