@wpmoo/ui 1.0.0-rc.9 → 1.0.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/ASSET_LICENSE.md +1 -1
- package/LICENSE +28 -0
- package/README.md +31 -3
- package/certification.json +2 -1
- package/dist/assets/css/moo-ui.css +381 -22
- package/dist/assets/css/moo-ui.min.css +10 -31
- package/dist/assets/css/moo.css +373 -21
- package/dist/assets/css/moo.min.css +10 -32
- package/dist/js/chart.js +23 -21
- package/dist/js/chart.min.js +5 -5
- package/dist/js/combobox.js +18 -65
- package/dist/js/context-menu.js +16 -68
- package/dist/js/datatable.js +38 -21
- package/dist/js/datepicker.js +3 -2
- package/dist/js/datepicker.min.js +4 -3
- package/dist/js/moo-ui.js +158 -15400
- package/dist/js/moo-ui.min.js +3 -23
- package/dist/js/sheet.js +46 -0
- package/dist/js/sidebar.js +3 -2
- package/dist/js/slider.js +12 -47
- package/dist/js/state.js +15 -41
- package/dist/release-manifest.json +4 -4
- package/package.json +3 -1
- package/scss/_components.scss +2 -2
- package/scss/_config.scss +15 -21
- package/scss/_settings.scss +0 -3
- package/scss/components/_accordion.scss +1 -12
- package/scss/components/_alert.scss +1 -12
- package/scss/components/_avatar.scss +1 -16
- package/scss/components/_badge.scss +1 -0
- package/scss/components/_breadcrumb.scss +1 -12
- package/scss/components/_button.scss +1 -29
- package/scss/components/_button_group.scss +1 -25
- package/scss/components/_card.scss +1 -29
- package/scss/components/_checkbox.scss +1 -38
- package/scss/components/_close_button.scss +1 -9
- package/scss/components/_collapsible.scss +1 -0
- package/scss/components/_combobox.scss +1 -6
- package/scss/components/_context-menu.scss +1 -11
- package/scss/components/_datatable.scss +46 -85
- package/scss/components/_datepicker.scss +1 -0
- package/scss/components/_dialog.scss +1 -14
- package/scss/components/_dropdown.scss +5 -51
- package/scss/components/_field.scss +1 -40
- package/scss/components/_input.scss +1 -5
- package/scss/components/_input_group.scss +1 -51
- package/scss/components/_kbd.scss +1 -0
- package/scss/components/_menubar.scss +1 -0
- package/scss/components/_navigation.scss +76 -6
- package/scss/components/_pagination.scss +1 -13
- package/scss/components/_popover.scss +1 -22
- package/scss/components/_progress.scss +1 -3
- package/scss/components/_radio_group.scss +105 -6
- package/scss/components/_search_trigger.scss +1 -2
- package/scss/components/_select.scss +1 -0
- package/scss/components/_separator.scss +1 -6
- package/scss/components/_sheet.scss +1 -17
- package/scss/components/_sidebar.scss +1 -2
- package/scss/components/_skeleton.scss +1 -8
- package/scss/components/_slider.scss +1 -2
- package/scss/components/_spinner.scss +1 -7
- package/scss/components/_switch.scss +1 -4
- package/scss/components/_table.scss +1 -2
- package/scss/components/_tabs.scss +1 -24
- package/scss/components/_textarea.scss +1 -0
- package/scss/components/_toast.scss +1 -4
- package/scss/components/_toggle_group.scss +1 -3
- package/scss/components/_tooltip.scss +1 -20
- package/scss/components/sidebar/_base.scss +0 -7
- package/scss/components/sidebar/_collapsed.scss +0 -6
- package/scss/components/sidebar/_identity.scss +0 -1
- package/scss/components/sidebar/_menus.scss +0 -17
- package/scss/foundations/_backdrop.scss +0 -26
- package/scss/foundations/_focus.scss +0 -56
- package/scss/foundations/_scope.scss +14 -0
- package/scss/layouts/_app.scss +0 -6
- package/scss/layouts/_page_grid.scss +0 -3
- package/scss/layouts/app/sidebar/_base.scss +0 -33
- package/scss/layouts/app/sidebar/_default.scss +0 -6
- package/scss/layouts/app/sidebar/_floating.scss +0 -11
- package/scss/layouts/app/sidebar/_inset.scss +0 -2
- package/scss/mixins/_banner.scss +9 -3
- package/scss/moo-core.scss +3 -6
- package/scss/moo-ui.scss +9 -5
- package/scss/settings/_bootstrap_overrides.scss +0 -8
- package/scss/settings/_component_variables.scss +4 -266
- package/scss/settings/_forms.scss +0 -37
- package/scss/settings/_palette.scss +0 -42
- package/scss/themes/_root.scss +3 -0
- package/scss/themes/_standalone.scss +0 -2
- package/scss/themes/_theme.scss +3 -2
- package/scss/utilities/_background_color.scss +18 -0
- package/scss/utilities/_border.scss +4 -0
|
@@ -1,13 +1,27 @@
|
|
|
1
1
|
@scope (.moo-ui) to (:where(.moo-ui[data-bs-theme="light"], .moo-ui[data-bs-theme="dark"])) {
|
|
2
2
|
@import "../components";
|
|
3
|
+
/* Focus and keyboard navigation */
|
|
3
4
|
@import "../foundations/focus";
|
|
5
|
+
/* Utilities */
|
|
6
|
+
@import "../utilities/border";
|
|
4
7
|
@import "../utilities/scroll_fade";
|
|
8
|
+
/* Application layout */
|
|
5
9
|
@import "../layouts/app";
|
|
6
10
|
@import "../layouts/page_grid";
|
|
11
|
+
/* Form themes */
|
|
7
12
|
@import "../themes/forms";
|
|
13
|
+
/* Overlay backdrops */
|
|
8
14
|
@include moo-overlay-backdrop-scoped;
|
|
15
|
+
/* Typography */
|
|
9
16
|
:where(h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6,
|
|
10
17
|
.display-1, .display-2, .display-3, .display-4, .display-5, .display-6) {
|
|
11
18
|
font-family: var(--moo-heading-font-family, var(--bs-body-font-family));
|
|
12
19
|
}
|
|
20
|
+
:is(small, .small) {
|
|
21
|
+
font-size: var(--moo-small-font-size);
|
|
22
|
+
}
|
|
23
|
+
p {
|
|
24
|
+
margin-top: var(--moo-paragraph-margin-top);
|
|
25
|
+
margin-bottom: var(--moo-paragraph-margin-bottom);
|
|
26
|
+
}
|
|
13
27
|
}
|
package/scss/layouts/_app.scss
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
// Application layout owns the shell and page geometry.
|
|
2
|
-
// It is intentionally separate from component surfaces such as Sidebar.
|
|
3
1
|
|
|
4
2
|
@import "app/sidebar/base";
|
|
5
3
|
@import "app/sidebar/default";
|
|
@@ -36,10 +34,6 @@
|
|
|
36
34
|
flex: 0 0 auto;
|
|
37
35
|
}
|
|
38
36
|
|
|
39
|
-
// The page main region owns the space between the optional header and footer.
|
|
40
|
-
// Keep the Bootstrap rail as the flex column too, so app previews and real
|
|
41
|
-
// shells can give their caller content a full-height surface without adding
|
|
42
|
-
// layout-specific height values.
|
|
43
37
|
.wrapper[data-layout="app"] > [data-slot="page"] > main {
|
|
44
38
|
display: flex;
|
|
45
39
|
min-height: 0;
|
|
@@ -1,10 +1,7 @@
|
|
|
1
|
-
// Opt-in Bootstrap row geometry keyed to the usable Moo Page rail, not the
|
|
2
|
-
// viewport or the optional Sidebar state. The rail itself is the query owner.
|
|
3
1
|
[data-page-container] {
|
|
4
2
|
container: moo-page / inline-size;
|
|
5
3
|
}
|
|
6
4
|
|
|
7
|
-
// Keep the compact branch usable in browsers without container queries.
|
|
8
5
|
[data-page-container] [data-page-show-from] {
|
|
9
6
|
display: none !important;
|
|
10
7
|
}
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
// Shared App-owned Sidebar shell geometry. Sidebar's component partials own
|
|
2
|
-
// only the inner surface and navigation anatomy.
|
|
3
1
|
|
|
4
2
|
.sidebar {
|
|
5
3
|
--moo-sidebar-width: #{$moo-sidebar-width};
|
|
@@ -10,7 +8,6 @@
|
|
|
10
8
|
color: var(--moo-sidebar-foreground);
|
|
11
9
|
}
|
|
12
10
|
|
|
13
|
-
// Rail: a thin toggle strip straddling the Sidebar's inline-end edge.
|
|
14
11
|
.sidebar-rail {
|
|
15
12
|
position: absolute;
|
|
16
13
|
inset-block: 0;
|
|
@@ -24,8 +21,6 @@
|
|
|
24
21
|
cursor: pointer;
|
|
25
22
|
}
|
|
26
23
|
|
|
27
|
-
// Read the Sidebar's computed direction so this remains valid inside the
|
|
28
|
-
// resolved-owner @scope as well as under a full-document html[dir] owner.
|
|
29
24
|
.sidebar:dir(rtl) .sidebar-rail {
|
|
30
25
|
transform: translateX(-50%);
|
|
31
26
|
}
|
|
@@ -50,17 +45,11 @@
|
|
|
50
45
|
max-height: 100%;
|
|
51
46
|
}
|
|
52
47
|
|
|
53
|
-
// The outer shell owns stacking, collapse width, and the contained-shell
|
|
54
|
-
// geometry. Inner collapsed content remains in components/sidebar/_collapsed.
|
|
55
48
|
@include media-breakpoint-up(lg) {
|
|
56
49
|
.sidebar {
|
|
57
50
|
position: relative;
|
|
58
51
|
}
|
|
59
52
|
|
|
60
|
-
// `offcanvas` is a collapsible mode, not a visual Sidebar variant. On
|
|
61
|
-
// desktop the App keeps the shell in normal flow and uses the shared App
|
|
62
|
-
// state attribute to collapse the column; below lg Bootstrap's native
|
|
63
|
-
// Offcanvas plugin continues to own the drawer transition.
|
|
64
53
|
.sidebar.offcanvas-lg[data-collapsible="offcanvas"] {
|
|
65
54
|
visibility: visible;
|
|
66
55
|
transform: none;
|
|
@@ -75,16 +64,9 @@
|
|
|
75
64
|
|
|
76
65
|
.wrapper[data-layout="app"]:has([data-sidebar-dropdown-positioned] > .dropdown-menu.show) > .sidebar {
|
|
77
66
|
position: relative;
|
|
78
|
-
// Catalog page headers are sticky at $zindex-fixed. The Sidebar root must
|
|
79
|
-
// sit above that page-level stacking context while an identity menu is
|
|
80
|
-
// open, otherwise the workspace menu is painted underneath the header
|
|
81
|
-
// even though the menu itself is fixed and has dropdown z-index.
|
|
82
67
|
z-index: $zindex-fixed + 1;
|
|
83
68
|
}
|
|
84
69
|
|
|
85
|
-
// The sticky inner surface is its own stacking context. Elevate that
|
|
86
|
-
// context while an identity menu is open so the rail's hover indicator
|
|
87
|
-
// remains behind the fixed dropdown instead of painting across it.
|
|
88
70
|
.wrapper[data-layout="app"]:has([data-sidebar-dropdown-positioned] > .dropdown-menu.show) > .sidebar > .sidebar-inner {
|
|
89
71
|
z-index: $zindex-fixed + 1;
|
|
90
72
|
}
|
|
@@ -99,19 +81,4 @@
|
|
|
99
81
|
.sidebar-rail {
|
|
100
82
|
display: none;
|
|
101
83
|
}
|
|
102
|
-
|
|
103
|
-
.wrapper[data-layout="app"][data-shell-mode="contained"] .sidebar {
|
|
104
|
-
position: relative;
|
|
105
|
-
inset: auto;
|
|
106
|
-
flex: 0 0 auto;
|
|
107
|
-
width: 100%;
|
|
108
|
-
height: auto;
|
|
109
|
-
visibility: visible;
|
|
110
|
-
transform: none;
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
.wrapper[data-layout="app"][data-shell-mode="contained"] .sidebar-inner {
|
|
114
|
-
height: auto;
|
|
115
|
-
max-height: none;
|
|
116
|
-
}
|
|
117
84
|
}
|
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
// Attached Sidebar variants keep a divider at the shell edge; Inset does not.
|
|
2
1
|
|
|
3
2
|
.sidebar[data-side="left"]:not([data-variant="inset"]) .sidebar-inner {
|
|
4
|
-
// `side` is a physical placement contract. Keep the divider on the
|
|
5
|
-
// Sidebar/Page boundary when the document direction is RTL as well.
|
|
6
3
|
border-right: var(--bs-border-width) solid var(--moo-sidebar-border);
|
|
7
4
|
}
|
|
8
5
|
|
|
@@ -10,9 +7,6 @@
|
|
|
10
7
|
order: 1;
|
|
11
8
|
}
|
|
12
9
|
|
|
13
|
-
// `side` is a physical placement contract. `:dir()` reads the wrapper's
|
|
14
|
-
// computed direction inside the owner scope, whether it comes from html for a
|
|
15
|
-
// document owner or from an embedded owner's own dir attribute.
|
|
16
10
|
.wrapper[data-layout="app"]:dir(rtl) > .sidebar[data-side="left"] {
|
|
17
11
|
order: 1;
|
|
18
12
|
}
|
|
@@ -1,10 +1,5 @@
|
|
|
1
|
-
// Floating App Sidebar variant: the shell detaches the inner surface from
|
|
2
|
-
// the viewport edge with a margin, border, radius, and shadow.
|
|
3
1
|
|
|
4
2
|
@include media-breakpoint-up(lg) {
|
|
5
|
-
// Enable shell motion only after Sidebar has restored its initial state.
|
|
6
|
-
// Hosts that hydrate after first paint must not animate the correction from
|
|
7
|
-
// their server/default state to the persisted state.
|
|
8
3
|
:where(.wrapper[data-layout="app"][data-sidebar-ready]) > .sidebar {
|
|
9
4
|
transition: flex-basis 0.2s ease, width 0.2s ease;
|
|
10
5
|
}
|
|
@@ -24,12 +19,6 @@
|
|
|
24
19
|
max-height: calc(100% - #{$spacer});
|
|
25
20
|
}
|
|
26
21
|
|
|
27
|
-
// At icon-rail width the detached card reads as floating mostly through
|
|
28
|
-
// elevation and breathing room, since the margin/border alone are hard to
|
|
29
|
-
// read at the base icon width; step up to Bootstrap's base shadow scale
|
|
30
|
-
// (still a shared token, no new value) and widen the column by the same
|
|
31
|
-
// margin the card's sides consume, so the icon rail itself keeps its full
|
|
32
|
-
// width instead of shrinking.
|
|
33
22
|
.wrapper[data-layout="app"][data-sidebar-state="collapsed"] .sidebar[data-variant="floating"][data-collapsible="icon"] {
|
|
34
23
|
flex-basis: calc(var(--moo-sidebar-width-icon) + #{$spacer});
|
|
35
24
|
width: calc(var(--moo-sidebar-width-icon) + #{$spacer});
|
package/scss/mixins/_banner.scss
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
/*!
|
|
2
|
+
* Moo UI v1.0.0 (https://wpmoo.org/)
|
|
3
|
+
* Copyright 2026 WPMoo Authors
|
|
4
|
+
* Licensed under MIT (https://github.com/wpmoo-org/ui/blob/main/LICENSE)
|
|
5
|
+
*
|
|
6
|
+
* Bootstrap v5.3.3 (https://getbootstrap.com/)
|
|
7
|
+
* Copyright 2011-2024 The Bootstrap Authors
|
|
8
|
+
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
9
|
+
*/
|
package/scss/moo-core.scss
CHANGED
|
@@ -1,9 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
* Moo UI core
|
|
3
|
-
* Copyright (c) 2026 WPMoo (wpmoo.org)
|
|
4
|
-
* Includes Bootstrap 5.3.3 component output
|
|
5
|
-
* SPDX-License-Identifier: MIT
|
|
6
|
-
*/
|
|
1
|
+
@import "mixins/banner";
|
|
7
2
|
@import "settings/options";
|
|
8
3
|
@import "bootstrap/scss/functions";
|
|
9
4
|
@import "settings";
|
|
@@ -13,7 +8,9 @@
|
|
|
13
8
|
@import "bootstrap/scss/mixins";
|
|
14
9
|
@import "bootstrap/scss/utilities";
|
|
15
10
|
@import "themes/theme";
|
|
11
|
+
/* Global styles */
|
|
16
12
|
@import "foundations/globals";
|
|
17
13
|
@import "foundations/backdrop";
|
|
14
|
+
/* Theme tokens */
|
|
18
15
|
@import "themes/root";
|
|
19
16
|
@import "foundations/scope";
|
package/scss/moo-ui.scss
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
@import "settings";
|
|
2
1
|
@import "mixins/banner";
|
|
2
|
+
@import "settings";
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
/* Bootstrap configuration */
|
|
5
5
|
@import "bootstrap/scss/functions";
|
|
6
6
|
@import "bootstrap/scss/variables";
|
|
7
7
|
@import "bootstrap/scss/variables-dark";
|
|
@@ -10,13 +10,16 @@
|
|
|
10
10
|
@import "bootstrap/scss/utilities";
|
|
11
11
|
@import "themes/theme";
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
/* Bootstrap layout and standalone-only components */
|
|
14
14
|
@import "bootstrap/scss/root";
|
|
15
|
+
/* Theme tokens */
|
|
15
16
|
@import "themes/root";
|
|
16
17
|
@import "themes/standalone";
|
|
18
|
+
/* Base styles and typography */
|
|
17
19
|
@import "bootstrap/scss/reboot";
|
|
18
20
|
@import "bootstrap/scss/type";
|
|
19
21
|
@import "bootstrap/scss/images";
|
|
22
|
+
/* Containers and grid */
|
|
20
23
|
@import "bootstrap/scss/containers";
|
|
21
24
|
@import "bootstrap/scss/grid";
|
|
22
25
|
@import "bootstrap/scss/forms/form-range";
|
|
@@ -29,7 +32,7 @@
|
|
|
29
32
|
@import "bootstrap/scss/spinners";
|
|
30
33
|
@import "bootstrap/scss/placeholders";
|
|
31
34
|
|
|
32
|
-
|
|
35
|
+
/* Bootstrap helpers */
|
|
33
36
|
@import "bootstrap/scss/helpers/clearfix";
|
|
34
37
|
@import "bootstrap/scss/helpers/colored-links";
|
|
35
38
|
@import "bootstrap/scss/helpers/focus-ring";
|
|
@@ -42,7 +45,8 @@
|
|
|
42
45
|
@import "bootstrap/scss/helpers/text-truncation";
|
|
43
46
|
@import "bootstrap/scss/helpers/vr";
|
|
44
47
|
|
|
45
|
-
|
|
48
|
+
/* Bootstrap utilities */
|
|
49
|
+
@import "utilities/background_color";
|
|
46
50
|
@import "bootstrap/scss/utilities/api";
|
|
47
51
|
|
|
48
52
|
@import "utilities/scroll_fade_primitives";
|
|
@@ -1,15 +1,7 @@
|
|
|
1
|
-
// Moo buttons use a subtle transform for the pressed state, so Bootstrap's
|
|
2
|
-
// native inset shadow press effect is disabled at the source.
|
|
3
1
|
$btn-box-shadow: none !default;
|
|
4
2
|
$btn-focus-box-shadow: none !default;
|
|
5
3
|
$btn-active-box-shadow: none !default;
|
|
6
4
|
|
|
7
|
-
// Keep Bootstrap's CSS Grid utility layer available alongside the Flexbox
|
|
8
|
-
// grid so native .grid and .g-col-* markup works in Moo UI hosts.
|
|
9
5
|
$enable-cssgrid: true !default;
|
|
10
6
|
|
|
11
|
-
// Bootstrap validation icons are background images injected by the native
|
|
12
|
-
// validation mixin. Reference-style invalid fields use border/ring + error text
|
|
13
|
-
// without a trailing status glyph, so disable the Bootstrap icon branch at the
|
|
14
|
-
// source while keeping .is-invalid/.invalid-feedback behavior.
|
|
15
7
|
$enable-validation-icons: false !default;
|