@inglorious/ui 9.5.1 → 9.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -40,8 +40,11 @@ The public CSS exports are:
40
40
  - `@inglorious/ui/base.css`
41
41
  - `@inglorious/ui/tokens.css`
42
42
  - `@inglorious/ui/themes/inglorious.css`
43
- - `@inglorious/ui/themes/material.css`
43
+ - `@inglorious/ui/themes/material-ui.css`
44
+ - `@inglorious/ui/themes/material-3.css`
44
45
  - `@inglorious/ui/themes/bootstrap.css`
46
+ - `@inglorious/ui/themes/ios-18.css`
47
+ - `@inglorious/ui/themes/ios-26.css`
45
48
  - `@inglorious/ui/all.css`
46
49
 
47
50
  ## Icons
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inglorious/ui",
3
- "version": "9.5.1",
3
+ "version": "9.6.0",
4
4
  "description": "A design system for Inglorious Web with render-function components and customizable themes",
5
5
  "author": "Matteo Antony Mistretta <antony.mistretta@gmail.com> (https://ingloriouscoderz.it)",
6
6
  "license": "MIT",
@@ -37,8 +37,11 @@
37
37
  "./tokens.css": "./src/styles/tokens.css",
38
38
  "./safe-area.css": "./src/styles/safe-area.css",
39
39
  "./themes/inglorious.css": "./src/styles/themes/inglorious.css",
40
- "./themes/material.css": "./src/styles/themes/material.css",
40
+ "./themes/material-ui.css": "./src/styles/themes/material-ui.css",
41
+ "./themes/material-3.css": "./src/styles/themes/material-3.css",
41
42
  "./themes/bootstrap.css": "./src/styles/themes/bootstrap.css",
43
+ "./themes/ios-18.css": "./src/styles/themes/ios-18.css",
44
+ "./themes/ios-26.css": "./src/styles/themes/ios-26.css",
42
45
  "./before-after": {
43
46
  "types": "./types/data-display/before-after.d.ts",
44
47
  "import": "./src/data-display/before-after/index.js"
@@ -28,6 +28,7 @@
28
28
  padding: 0 var(--iw-space-3);
29
29
  border: 1px solid var(--iw-input-border);
30
30
  border-radius: var(--iw-input-radius);
31
+ background-color: var(--iw-input-bg);
31
32
  transition:
32
33
  border-color var(--iw-transition-fast),
33
34
  box-shadow var(--iw-transition-fast),
@@ -1,6 +1,9 @@
1
1
  import android from "@iconify-icons/fa7-brands/android"
2
+ import apple from "@iconify-icons/fa7-brands/apple"
2
3
  import bootstrap from "@iconify-icons/fa7-brands/bootstrap"
4
+ import react from "@iconify-icons/fa7-brands/react"
3
5
  import gamepad from "@iconify-icons/fa7-solid/gamepad"
6
+ import mobile from "@iconify-icons/fa7-solid/mobile"
4
7
  import contrastOutline from "@iconify-icons/material-symbols/contrast-outline"
5
8
  import darkModeOutline from "@iconify-icons/material-symbols/dark-mode-outline"
6
9
  import formatListBulletedOutline from "@iconify-icons/material-symbols/format-list-bulleted-outline"
@@ -18,18 +21,22 @@ import { Flex } from "../../layout/flex/index.js"
18
21
  import { Breadcrumbs } from "../../navigation/breadcrumbs/index.js"
19
22
  import { AppBar } from "../../surfaces/app-bar/index.js"
20
23
 
24
+ const THEME_ICONS = {
25
+ inglorious: gamepad,
26
+ "material-ui": react,
27
+ "material-3": android,
28
+ bootstrap,
29
+ "ios-18": mobile,
30
+ "ios-26": apple,
31
+ }
32
+
21
33
  export const AppHeader = {
22
34
  render(entity, api) {
23
35
  const themeEntity = api.getEntity("theme")
24
36
  const modeEntity = api.getEntity("mode")
25
37
  const themeMode = modeEntity?.mode ?? "auto"
26
38
  const themeName = themeEntity?.theme ?? "inglorious"
27
- const themeIcon =
28
- themeName === "bootstrap"
29
- ? bootstrap
30
- : themeName === "material"
31
- ? android
32
- : gamepad
39
+ const themeIcon = THEME_ICONS[themeName] ?? gamepad
33
40
  const modeIcon =
34
41
  themeMode === "light"
35
42
  ? lightModeOutline
@@ -79,6 +79,7 @@
79
79
 
80
80
  .iw-dashboard-stat {
81
81
  overflow: hidden;
82
+ color: white;
82
83
 
83
84
  .iw-typography,
84
85
  .iw-icon,
@@ -1,6 +1,13 @@
1
1
  const DEFAULT_THEME = "inglorious"
2
2
  const DEFAULT_MODE = "auto"
3
- const THEME_CYCLE = ["inglorious", "material", "bootstrap"]
3
+ const THEME_CYCLE = [
4
+ "inglorious",
5
+ "material-ui",
6
+ "material-3",
7
+ "bootstrap",
8
+ "ios-18",
9
+ "ios-26",
10
+ ]
4
11
  const MODE_CYCLE = ["auto", "light", "dark"]
5
12
 
6
13
  let currentTheme = DEFAULT_THEME
@@ -21,7 +28,7 @@ export function applyTheme(theme = currentTheme, mode = currentMode) {
21
28
  resolvedMode === "light" ? "iw-theme-light" : "iw-theme-dark"
22
29
 
23
30
  document.body.className = document.body.className.replace(
24
- /iw-theme-(\w+)/g,
31
+ /iw-theme-([\w-]+)/g,
25
32
  "",
26
33
  )
27
34
  document.body.classList.add(themeClass, modeClass)