Инструменты пользователя

Инструменты сайта


devel:style.ini

Различия

Показаны различия между двумя версиями страницы.

Ссылка на это сравнение

devel:style.ini [2023/08/28 13:54] – создано vladpolskiydevel:style.ini [Дата неизвестна] (текущий) – удалено - внешнее изменение (Дата неизвестна) 127.0.0.1
Строка 1: Строка 1:
-====== Шаблон style.ini ====== 
  
-The ''style.ini'' is an [[wp>INI_file|ini file]] in each [[template]]'s directory((if the template supports it)) configuring the generation of [[CSS]] styles. It has two sections: [stylesheets] and [replacements] described below. 
- 
-===== [stylesheets] ===== 
- 
-This part defines which CSS files are loaded. Each line is defined as follow: 
- 
-  cssfile.css = mode 
- 
-''cssfile.css'' is your file name and ''mode'' is one of the supported output modes as described at [[CSS#Stylesheet Modes|mode]]. 
- 
-The stylesheet can also be a ''.less'' file. (See [[LESS]]). 
- 
-===== [replacements] ===== 
- 
-DokuWiki's CSS dispatcher is able to replace placeholders in the loaded stylesheets which are configured through the ''[replacements]'' section in the templates ''style.ini''. This is especially useful for defining a color scheme once and reuse these colors in all files. 
- 
-These replacements can also be used as [[less#accessing_styleini_placeholders|LESS variables]]. 
- 
-The Styling Plugin let users preview and change the appearance of any template based on the defined replacements. See the [[plugin:styling|Styling Plugin]] for details. 
- 
-==== Guaranteed color placeholders ==== 
- 
-The following placeholders are the only ones that are safe to be used by plugins. All templates have to implement these at least, but are free to add more. 
- 
-^ placeholder variable        ^ meaning                                                                                 ^ 
-^ ''%%__background__%%''      | main background color                                                                   | 
-^ ''%%__background_alt__%%''  | alternative background color (also used for the theme color in the [[devel:manifest]])  | 
-^ ''%%__background_neu__%%''  | neutral background color                                                                | 
-^ ''%%__border__%%''          | border color                                                                            | 
-^ ''%%__text__%%''            | main text color                                                                         | 
-^ ''%%__text_alt__%%''        | alternative text color                                                                  | 
-^ ''%%__text_neu__%%''        | neutral text color                                                                      | 
-^ ''%%__highlight__%%''       | highlighted text color (**new** since Adora Belle)                                      | 
-^ ''%%__link__%%''            | the general link color (**new** since Greebo)                                           | 
- 
-Template authors should generally try to reuse the placeholder names of the default template. 
- 
-===== Example ===== 
- 
-See for example the [[https://github.com/selfthinker/dokuwiki_template_starter/blob/master/style.ini|style.ini]] of the Starter template for an overview of the file. If your are a wiki admin who like to modify the style, please use a [[#local style.ini]]. 
- 
-===== Local style.ini ===== 
- 
- 
- 
-Loal changes can be stored in a local ''style.ini'' at the location ''conf/tpl/<tpl>/style.ini''. (Where ''<tpl>'' needs to be substituted with the name of the template folder. Just create it if it doesn't exist.) 
- 
-This prevents losing those changes after an upgrade. The file still needs to include each section (i.e. ''[stylesheets]'' or ''[replacements]'') and paths are relative to the added ini file. 
- 
-If you use the [[plugin:styling|{{https://raw.githubusercontent.com/dokuwiki/dokuwiki/master/lib/plugins/styling/admin.svg?16}}]][[plugin:styling|Styling Plugin]] you can preview and change the replacement values via the admin interface, before it is stored in this file. 
- 
-Example: 
- 
-<code ini conf/tpl/dokuwiki/style.ini> 
-[stylesheets] 
-extra.css  = all 
- 
-[replacements] 
-__text__        = "#000" 
-__site_width__  = "100%" 
-</code> 
devel/style.ini.1693220085.txt.gz · Последнее изменение: vladpolskiy