Compare commits

..

22 Commits

Author SHA1 Message Date
6c48ea2919 OrcasHub: Add updating instructions to the readme 2025-04-24 08:21:46 -07:00
c0f5a81c8a OrcasHub: Add footer links
Requires css styles from the userall.css file
2025-04-24 08:21:46 -07:00
b7e8c1b147 Orcashub: Add custom html pages 2025-04-24 08:21:46 -07:00
e866875ae2 OrcasHub: Tweak page title format 2025-04-24 08:21:46 -07:00
James Collins
68610d368e added support to default to dark theme #95 2025-04-24 22:28:26 +10:00
James Collins
a92686aa56 fix dynamic creation of variable depreciations 2025-04-24 22:26:26 +10:00
James Collins
c3587e9ae1 added fix for #102 - detect if mbstring is install before calling method 2025-04-24 21:40:27 +10:00
James Collins
d4ad0f6be4 added fix for #104 2025-04-24 21:26:34 +10:00
James Collins
76c148abcc version bump 2025-04-24 20:41:00 +10:00
Christoph Scholz
1a3781161f fix typo preventing logged_in_user from showing 2025-04-24 20:37:28 +10:00
James Collins
1b6906fb46
Merge pull request #91
Update Chinese language files
2025-04-24 20:33:20 +10:00
Little-data
97f78e898c
Merge branch 'nomadjimbob:main' into main 2024-12-30 20:33:33 +08:00
Little-data
de97337cb6
Synchronize upstream language changes(24.09.02) 2024-09-02 22:55:04 +08:00
Little-data
81dd065f27
Add "__navbar_search_max_width__" translate text 2024-08-31 22:08:26 +08:00
Little-data
303477907b
Merge branch 'nomadjimbob:main' into main 2024-08-31 22:03:27 +08:00
Little-data
c51a5c6ed6
add new part of lang.php from en 2024-07-14 16:18:15 +08:00
Little-data
2e94abfcde
Merge branch 'nomadjimbob:main' into main 2024-07-14 15:11:09 +08:00
Little-data
2d201299af
Synchronize upstream language changes 2024-06-24 16:48:14 +08:00
Little-data
cd93af7fd6
Create Chinese Simplified default.php 2024-06-20 16:12:57 +08:00
Little-data
89051ee20a
Create Chinese Simplified metadata.php 2024-06-20 16:12:03 +08:00
Little-data
68fe299a33
Create Chinese Simplified settings.php 2024-06-20 16:09:44 +08:00
Little-data
a8763fe1bf
Create Chinese Simplified lang.php 2024-06-20 16:07:21 +08:00
12 changed files with 87 additions and 19 deletions

View File

@ -271,8 +271,15 @@ If the plugin is installed, the **Template Styles Settings** page will be expand
## Releases
- **_2024-09-01 RC-1_**
- **_NEXT_**
- Added support to default to dark theme in the template options [#95](https://github.com/nomadjimbob/mikio/issues/95). Requested by jeffka11.
- Fix dynamic variable creation depreciation warnings in the lessc engine
- Will now detect if `mbstring` is missing from your PHP installation is not use these helper methods [#102](https://github.com/nomadjimbob/mikio/issues/102). Thanks Naomitor.
- Fixed overflow bug with large number of trace items on small displays [#104](https://github.com/nomadjimbob/mikio/issues/104). Thanks looowizz.
- **_2025-04-24_**
- Fix typo preventing logged_in_user from showing [#105](https://github.com/nomadjimbob/mikio/pull/105). Thanks ChaosKid42.
- Added support for the Chinese language [#91](https://github.com/nomadjimbob/mikio/pull/91). Thanks Little-data.
- `navbarTitleIconHeight` and `navbarTitleIconWidth` will now override any automatic navbar logo height and width which fixes non-square SVGs [#98](https://github.com/nomadjimbob/mikio/issues/98). Thanks macin.
- Added support for Dark Mode logos in the navbar [#98](https://github.com/nomadjimbob/mikio/issues/98). Requested by macin.
- Fixed table alignments not being applied [#86](https://github.com/nomadjimbob/mikio/issues/86). Thanks aloade.

View File

@ -13,7 +13,7 @@ const mikio = {
stickyItems: [],
stickyOffset: 0,
stickyIndex: 2010,
darkMode: 'light',
darkMode: '',
ready: function () {
const updateStickyScroll = function () {
@ -451,6 +451,16 @@ const mikio = {
delete html.dataset.themeAuto;
}
console.log(this.darkMode);
if(themeMode === '') {
if(document.querySelector('body').classList.contains('mikio-default-dark')) {
themeMode = 'dark';
} else {
themeMode = 'light';
}
}
html.dataset.theme = `theme-${themeMode}`;
this.setCookie('lightDarkToggle', this.darkMode);
},

View File

@ -435,6 +435,7 @@ body {
.mikio-youarehere {
.mikio-container {
flex-direction: row;
flex-wrap: wrap;
}
padding: .5rem 1rem;

View File

@ -16,6 +16,7 @@ $conf['brandURLGuest'] = '';
$conf['brandURLUser'] = '';
$conf['showLightDark'] = 0;
$conf['autoLightDark'] = 0;
$conf['defaultDark'] = 0;
$conf['navbarUseTitleIcon'] = 1;
$conf['navbarTitleIconHeight'] = '';

View File

@ -16,6 +16,7 @@ $meta['brandURLGuest'] = ['string'];
$meta['brandURLUser'] = ['string'];
$meta['showLightDark'] = ['onoff'];
$meta['autoLightDark'] = ['onoff'];
$meta['defaultDark'] = ['onoff'];
$meta['navbarUseTitleIcon'] = ['onoff'];
$meta['navbarTitleIconHeight'] = ['string'];

View File

@ -1,7 +1,7 @@
<?php
/**
* lessphp v0.7.0
* lessphp v0.7.1
* http://leafo.net/lessphp
*
* LESS CSS compiler, adapted from http://lesscss.org
@ -40,7 +40,7 @@
* handling things like indentation.
*/
class lessc {
static public $VERSION = "v0.7.0";
static public $VERSION = "v0.7.1";
static public $TRUE = array("keyword", "true");
static public $FALSE = array("keyword", "false");
@ -72,6 +72,11 @@ class lessc {
static protected $nextImportId = 0; // uniquely identify imports
protected $parser;
protected $env;
protected $scope;
protected $formatter;
// attempts to find the path of an import url, returns null for css files
protected function findImport($url) {
foreach ((array)$this->importDir as $dir) {
@ -1377,7 +1382,7 @@ class lessc {
$name = $name . ": ";
}
$this->throwError("${name}expecting $expectedArgs arguments, got $numValues");
$this->throwError("{$name}expecting $expectedArgs arguments, got $numValues");
}
return $values;
@ -1393,7 +1398,7 @@ class lessc {
$name = $name . ": ";
}
$this->throwError("${name}expecting at least $expectedMinArgs arguments, got $numValues");
$this->throwError("{$name}expecting at least $expectedMinArgs arguments, got $numValues");
}
return $values;
@ -1738,7 +1743,7 @@ class lessc {
}
// type based operators
$fname = "op_${ltype}_${rtype}";
$fname = "op_{$ltype}_{$rtype}";
if (is_callable(array($this, $fname))) {
$out = $this->$fname($op, $left, $right);
if (!is_null($out)) return $out;
@ -2551,6 +2556,18 @@ class lessc_parser {
// caches preg escaped literals
static protected $literalCache = array();
protected $eatWhiteDefault;
protected $lessc;
protected $sourceName;
public $writeComments;
public $count;
protected $line;
protected $env;
public $buffer;
protected $seenComments;
protected $inExp;
public function __construct($lessc, $sourceName = null) {
$this->eatWhiteDefault = true;
// reference to less needed for vPrefix, mPrefix, and parentSelector
@ -4017,6 +4034,7 @@ class lessc_formatter_lessjs extends lessc_formatter_classic {
public $breakSelectors = true;
public $assignSeparator = ": ";
public $selectorSeparator = ",";
public $indentLevel;
}

View File

@ -19,6 +19,7 @@ $lang['brandURLGuest'] = 'Change the Brand Logo URL for guests. Leave b
$lang['brandURLUser'] = 'Change the Brand Logo URL for logged in users. Leave blank for default home URL';
$lang['showLightDark'] = 'Show the light/dark toggle in the navbar';
$lang['autoLightDark'] = 'Change light/dark theme based on the system preference';
$lang['defaultDark'] = 'Default to the dark theme for the user';
$lang['navbarUseTitleIcon'] = 'Show the wiki image in the menubar title. Will search for an image named logo
(png/jpg/gif/svg) in the root or :wiki: namespace or the template/subtheme images directory';

View File

@ -29,6 +29,7 @@ $lang['config_license'] = '许可';
$lang['config_acl'] = '权限';
$lang['config_sticky'] = '粘性部件';
/* Setting Values */
$lang['value_never'] = '从不';
$lang['value_admin'] = '管理员';
@ -58,6 +59,10 @@ $lang['value_page_editors'] = '页面编辑者';
$lang['value_badge'] = '徽章';
$lang['value_button'] = '按钮';
/* Style.ini */
$lang['__link__'] = '链接文字颜色';
$lang['__link_hover__'] = '光标悬停在链接上时文字颜色';
@ -75,10 +80,12 @@ $lang['__line_height__'] = '基本字体行高';
$lang['__site_width__'] = '正文内容宽度';
$lang['__font_size__'] = '基本字号';
$lang['__font_family__'] = '基本字体集(包含空格的字体必须使用引号。多个字体可以用逗号隔开)';
$lang['__font_family__'] = '基本字体集(包含空格的字体必须使用引号。
多个字体可以用逗号隔开)';
$lang['__admin_background_color__'] = '管理页面背景颜色';
$lang['__code_font_family__'] = '代码块字体集(包含空格的字体必须加引号。可使用逗号分隔多种字体)';
$lang['__code_font_family__'] = '代码块字体集(包含空格的字体必须加引号。
可使用逗号分隔多种字体)';
$lang['__code_font_size__'] = '代码块字体大小';
$lang['__code_text_color__'] = '代码块字体颜色';
$lang['__code_background_color__'] = '代码块背景颜色';
@ -95,18 +102,22 @@ $lang['__button_border_color__'] = '按钮边框颜色';
$lang['__button_text_hover_color__'] = '光标悬停时按钮字体颜色';
$lang['__button_background_hover_color__'] = '光标悬停时按钮的背景颜色';
$lang['__button_border_hover_color__'] = '光标悬停时按钮的边框颜色';
$lang['__input_text_color__'] = '输入字段的文本颜色';
$lang['__input_border_color__'] = '控件的边框颜色';
$lang['__input_background_color__'] = '输入字段的背景颜色';
$lang['__button_default_text_color__'] = '默认按钮的字体颜色';
$lang['__button_default_background_color__'] = '默认按钮的背景颜色';
$lang['__button_default_border_color__'] = '默认按钮的边框颜色';
$lang['__button_default_text_hover_color__'] = '光标悬停在默认按钮上时的字体颜色';
$lang['__button_default_background_hover_color__'] = '光标悬停时默认按钮的背景颜色';
$lang['__button_default_background_hover_color__'] = '光标悬停时默认
按钮的背景颜色';
$lang['__button_default_border_hover_color__'] = '光标悬停时默认按钮的边框颜色';
$lang['__button_search_text_color__'] = '搜索按钮的字体颜色';
$lang['__button_search_background_color__'] = '搜索按钮的背景颜色';
$lang['__button_search_border_color__'] = '搜索按钮的边框颜色';
$lang['__button_search_text_hover_color__'] = '光标悬停在搜索按钮上时的字体颜色';
$lang['__button_search_background_hover_color__'] = '光标悬停在搜索按钮上时搜索按钮的背景颜色';
$lang['__button_search_background_hover_color__'] = '光标悬停在搜索按钮上时
搜索按钮的背景颜色';
$lang['__button_search_border_hover_color__'] = '光标悬停在搜索按钮上时的边框颜色';
$lang['__topheader_background_color__'] = '标题顶部的背景颜色';
@ -116,16 +127,19 @@ $lang['__navbar_background_color__'] = '菜单的背景颜色';
$lang['__navbar_border_color__'] = '菜单的边框颜色';
$lang['__navbar_brand_text_color__'] = '网站标题的字体颜色';
$lang['__navbar_brand_tagline_color__'] = '网站标语的字体颜色';
$lang['__navbar_content_justify__'] = '网站菜单内容的排布(可以是 flex-start、flex-end、center、space-bween 或 space-around、space-between、space-around';
$lang['__navbar_content_justify__'] = '网站菜单内容的排布(可以是 flex-start、flex-end、center、space-bween
space-around、space-between、space-around';
$lang['__navbar_link_color__'] = '导航栏链接的字体颜色';
$lang['__navbar_link_hover_color__'] = '光标悬停在导航栏链接上时的字体颜色';
$lang['__navbar_search_max_width__'] = '搜索栏的最大宽度';
$lang['__subnavbar_text_color__'] = '子菜单文本的字体颜色';
$lang['__subnavbar_link_color__'] = '子菜单链接的字体颜色';
$lang['__subnavbar_link_hover_color__'] = '光标悬停在子菜单链接上时的字体颜色';
$lang['__subnavbar_background_color__'] = '子菜单的背景颜色';
$lang['__subnavbar_border_color__'] = '子菜单的边框颜色';
$lang['__subnavbar_content_justify__'] = '子菜单内容的排布(可以是 flex-start、flex-end、center、space-bween 或 space-around、space-between、space-around';
$lang['__subnavbar_content_justify__'] = '子菜单内容的排布(可以是 flex-start、flex-end、center、space-bween
space-around、space-between、space-around';
$lang['__tag_background_color__'] = '标签的背景颜色';
$lang['__tag_text_color__'] = '标签的字体颜色';
@ -198,6 +212,13 @@ $lang['__tab_active_color__'] = '活动选项卡的字体颜色';
$lang['__tab_active_background_color__'] = '活动选项卡的背景颜色';
$lang['__tab_active_border_color__'] = '活动选项卡的边框颜色';
$lang['__footnote_popup_font_size__'] = '脚注弹出窗口的字体大小';
$lang['__footnote_popup_text_color__'] = '脚注弹出窗口的字体颜色';
$lang['__footnote_popup_border_color__'] = '脚注弹出窗口的边框颜色';
$lang['__footnote_popup_background_color__'] = '脚注弹出窗口的背景颜色';
$lang['__footnote_popup_horizontal_padding__'] = '脚注弹出窗口的水平填充';
$lang['__footnote_popup_vertical_padding__'] = '脚注弹出窗口的垂直填充';
/* Plugin */
$lang['__plugin_background_color__'] = 'Mikio 插件元素的背景颜色';
$lang['__plugin_border_color__'] = 'Mikio 插件元素上使用的边框颜色';
@ -305,7 +326,8 @@ $lang['__plugin_steps_step_background_complete_color__'] = '已完成步骤
$lang['__plugin_tabgroup_tab_text_active_color__'] = '选项卡组活动选项卡字体颜色';
$lang['__plugin_tabgroup_tab_background_active_color__'] = '选项卡组活动选项卡背景颜色';
$lang['__plugin_tabgroup_tab_border_hover_color__'] = '光标悬停时选项卡组非活动选项卡边框颜色';
$lang['__plugin_tabgroup_tab_border_hover_color__'] = '光标悬停时选项卡组
非活动选项卡边框颜色';
$lang['__plugin_tooltip_text_color__'] = '工具提示字体颜色';
$lang['__plugin_tooltip_background_color__'] = '工具提示背景颜色';

View File

@ -16,6 +16,7 @@ $lang['brandURLGuest'] = '为访客更改徽标 URL。留空使用默
$lang['brandURLUser'] = '为登录用户更改徽标 URL。留空使用默认主页 URL';
$lang['showLightDark'] = '在导航栏显示明暗切换按钮';
$lang['autoLightDark'] = '根据系统主题更改明暗主题';
$lang['defaultDark'] = '默认为用户使用深色主题'; // added by nomadjimbob using translate.google.com
$lang['navbarUseTitleIcon'] = '在菜单栏标题中显示维基图片。将在根目录或 :wiki: 命名空间或模板/子主题图片目录中搜索名为logo的图片png/jpg/gif/svg。';
$lang['navbarTitleIconHeight'] = '直接设置标题图标高度。支持 像素px默认、相对单位rem 和 相对长度单位em';

View File

@ -38,7 +38,7 @@ ob_start();
tpl_includeFile('meta.html');
?>
</head>
<body class="mikio <?php echo $TEMPLATE->getConf('autoLightDark') === true ? ' mikio-auto-darklight' : '' ?>">
<body class="mikio<?php echo $TEMPLATE->getConf('autoLightDark') === true ? ' mikio-auto-darklight' : '' ?><?php echo $TEMPLATE->getConf('defaultDark') === true ? ' mikio-default-dark' : '' ?>">
<div id="dokuwiki__site">
<?php
echo '<div id="dokuwiki__top" class="site ' . tpl_classes() . (($showSidebar === true) ? ' showSidebar' : '') .

View File

@ -302,9 +302,9 @@ class mikio
],
['keys' => ['sidebarLeftRow1', 'sidebarLeftRow2', 'sidebarLeftRow3', 'sidebarLeftRow4'],
'type' => 'choice',
'values' => [tpl_getLang('value_none'), tpl_getLang('value_logged in user'), tpl_getLang('value_search'), tpl_getLang('value_content'), tpl_getLang('value_tags')],
'values' => [tpl_getLang('value_none'), tpl_getLang('value_logged_in_user'), tpl_getLang('value_search'), tpl_getLang('value_content'), tpl_getLang('value_tags')],
'default' => [
'sidebarLeftRow1' => tpl_getLang('value_logged in user'),
'sidebarLeftRow1' => tpl_getLang('value_logged_in_user'),
'sidebarLeftRow2' => tpl_getLang('value_search'),
'sidebarLeftRow3' => tpl_getLang('value_content')
]
@ -352,6 +352,7 @@ class mikio
['keys' => ['searchUseTypeahead'], 'type' => 'bool'],
['keys' => ['showLightDark'], 'type' => 'bool'],
['keys' => ['autoLightDark'], 'type' => 'bool'],
['keys' => ['defaultDark'], 'type' => 'bool'],
['keys' => ['youarehereShowLast'], 'type' => 'int'],
['keys' => ['iconTag'], 'type' => 'string'],
@ -2504,7 +2505,12 @@ height="16" fill="currentColor" viewBox="0 0 16 16"><path d="M4.545 6.714 4.11
$content = ob_get_clean();
if($content !== '') {
$domDocument = new DOMDocument();
$domContent = $domDocument->loadHTML(mb_convert_encoding($content, 'HTML-ENTITIES'));
if(function_exists('mb_convert_encoding')) {
$content = mb_convert_encoding($content, 'HTML-ENTITIES');
}
$domContent = $domDocument->loadHTML($content);
if (false === $domContent) {
return $content;
}

View File

@ -1,7 +1,7 @@
base mikio
author James Collins
email james.collins@outlook.com.au
date 2024-09-01
date 2025-04-24
name Mikio theme
desc Mikio template based on Bootstrap 4 with hero element for Dokuwiki
url https://www.dokuwiki.org/template:mikio