/
githubmirror
/
docusaurus
Обзор
Документация
Войти
/
githubmirror
/
docusaurus
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
packages/docusaurus-theme-common/src/components/ThemedComponent/styles.module.css
26 строк
598 B
Sébastien Lorber
fix(theme-common): ThemedComponent should display something when JS is disabled (#9243)
18 авг 2023, 18:11
Не верифицирован
18 авг 2023, 18:11
ca35268
Код
Авторство
О чём код?
/** * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ .themedComponent { display: none; } [data-theme='light'] .themedComponent--light { display: initial; } [data-theme='dark'] .themedComponent--dark { display: initial; } /* JS disabled??? Show light version by default => better than showing nothing TODO bad, but we currently always show light mode when there's no data-theme */ html:not([data-theme]) .themedComponent--light { display: initial; }