plutonium 0.32.0 → 0.33.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/app/assets/plutonium.css +2 -2
- data/lib/plutonium/ui/action_button.rb +5 -11
- data/lib/plutonium/ui/block.rb +1 -4
- data/lib/plutonium/ui/breadcrumbs.rb +8 -10
- data/lib/plutonium/ui/color_mode_selector.rb +2 -2
- data/lib/plutonium/ui/component/behaviour.rb +0 -8
- data/lib/plutonium/ui/component/kit.rb +1 -1
- data/lib/plutonium/ui/display/components/attachment.rb +2 -2
- data/lib/plutonium/ui/display/theme.rb +16 -16
- data/lib/plutonium/ui/empty_card.rb +2 -5
- data/lib/plutonium/ui/form/components/key_value_store.rb +11 -11
- data/lib/plutonium/ui/form/components/secure_association.rb +2 -2
- data/lib/plutonium/ui/form/components/uppy.rb +5 -5
- data/lib/plutonium/ui/form/concerns/renders_nested_resource_fields.rb +5 -5
- data/lib/plutonium/ui/form/query.rb +11 -11
- data/lib/plutonium/ui/form/resource.rb +2 -2
- data/lib/plutonium/ui/form/theme.rb +17 -17
- data/lib/plutonium/ui/layout/base.rb +2 -2
- data/lib/plutonium/ui/layout/header.rb +7 -10
- data/lib/plutonium/ui/layout/rodauth_layout.rb +5 -5
- data/lib/plutonium/ui/layout/sidebar.rb +2 -2
- data/lib/plutonium/ui/nav_grid_menu.rb +6 -6
- data/lib/plutonium/ui/nav_user.rb +7 -8
- data/lib/plutonium/ui/page/interactive_action.rb +4 -4
- data/lib/plutonium/ui/page_header.rb +4 -7
- data/lib/plutonium/ui/panel.rb +3 -3
- data/lib/plutonium/ui/sidebar_menu.rb +12 -12
- data/lib/plutonium/ui/skeleton_table.rb +8 -8
- data/lib/plutonium/ui/tab_list.rb +3 -5
- data/lib/plutonium/ui/table/components/attachment.rb +2 -2
- data/lib/plutonium/ui/table/components/pagy_info.rb +3 -3
- data/lib/plutonium/ui/table/components/pagy_pagination.rb +3 -3
- data/lib/plutonium/ui/table/components/scopes_bar.rb +14 -14
- data/lib/plutonium/ui/table/display_theme.rb +3 -3
- data/lib/plutonium/ui/table/resource.rb +2 -2
- data/lib/plutonium/ui/table/theme.rb +13 -13
- data/lib/plutonium/version.rb +1 -1
- data/package.json +1 -1
- data/src/css/core.css +2 -2
- data/src/css/easymde.css +8 -8
- data/src/css/intl_tel_input.css +7 -7
- data/src/css/slim_select.css +5 -5
- data/tailwind.options.js +2 -30
- metadata +1 -3
- data/docs/guide/theming.md +0 -431
- data/lib/plutonium/ui/component/theme.rb +0 -47
|
@@ -6,28 +6,28 @@ module Plutonium
|
|
|
6
6
|
class Theme < Phlexi::Table::Theme
|
|
7
7
|
def self.theme
|
|
8
8
|
super.merge({
|
|
9
|
-
selection_checkbox: "w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 rounded focus:ring-blue-500 dark:focus:ring-blue-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-
|
|
9
|
+
selection_checkbox: "w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 rounded focus:ring-blue-500 dark:focus:ring-blue-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600",
|
|
10
10
|
name_column: "font-medium text-gray-900 whitespace-nowrap dark:text-white",
|
|
11
11
|
align_start: "text-start",
|
|
12
12
|
align_end: "text-end",
|
|
13
|
-
wrapper: "
|
|
14
|
-
base: "
|
|
15
|
-
caption: "p-
|
|
16
|
-
description: "mt-
|
|
17
|
-
header: "
|
|
18
|
-
header_grouping_cell: "px-
|
|
19
|
-
header_cell: "
|
|
13
|
+
wrapper: "relative overflow-x-auto shadow-md sm:rounded-lg",
|
|
14
|
+
base: "w-full text-sm text-left rtl:text-right text-gray-500 dark:text-gray-400",
|
|
15
|
+
caption: "p-5 text-lg font-semibold text-left rtl:text-right text-gray-900 bg-white dark:text-white dark:bg-gray-800",
|
|
16
|
+
description: "mt-1 text-sm font-normal text-gray-500 dark:text-gray-400",
|
|
17
|
+
header: "text-xs text-gray-700 uppercase bg-gray-200 dark:bg-gray-700 dark:text-gray-400",
|
|
18
|
+
header_grouping_cell: "px-6 py-3 text-center text-sm border-b border-t border-r last:border-r-0 dark:border-gray-800",
|
|
19
|
+
header_cell: "px-6 py-3",
|
|
20
20
|
header_cell_content_wrapper: "inline-flex items-center",
|
|
21
21
|
header_cell_sort_wrapper: "flex items-center",
|
|
22
|
-
header_cell_sort_indicator: "ml-
|
|
23
|
-
body_row: "
|
|
24
|
-
body_cell: "
|
|
22
|
+
header_cell_sort_indicator: "ml-1.5",
|
|
23
|
+
body_row: "bg-white border-b last:border-none dark:bg-gray-800 dark:border-gray-700",
|
|
24
|
+
body_cell: "px-6 py-4 whitespace-pre max-w-[450px] overflow-hidden text-ellipsis transition-all duration-300 ease-in-out",
|
|
25
25
|
sort_icon: "w-3 h-3",
|
|
26
26
|
sort_icon_active: "text-primary-600",
|
|
27
27
|
sort_icon_inactive: "text-gray-600 dark:text-gray-500",
|
|
28
|
-
sort_index_clear_link: "ml-
|
|
28
|
+
sort_index_clear_link: "ml-2",
|
|
29
29
|
sort_index_clear_link_text: "text-xs font-bold text-gray-600 dark:text-gray-500",
|
|
30
|
-
sort_index_clear_link_icon: "ml-
|
|
30
|
+
sort_index_clear_link_icon: "ml-1 text-red-600"
|
|
31
31
|
})
|
|
32
32
|
end
|
|
33
33
|
end
|
data/lib/plutonium/version.rb
CHANGED
data/package.json
CHANGED
data/src/css/core.css
CHANGED
data/src/css/easymde.css
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
/* Container and CodeMirror theming */
|
|
8
8
|
.EasyMDEContainer .CodeMirror {
|
|
9
|
-
@apply border-gray-300 bg-
|
|
9
|
+
@apply border-gray-300 bg-white text-gray-900 dark:border-gray-600 dark:bg-gray-800 dark:text-gray-100;
|
|
10
10
|
}
|
|
11
11
|
|
|
12
12
|
.EasyMDEContainer .CodeMirror-focused .CodeMirror-selected {
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
|
|
32
32
|
/* Gutter theming */
|
|
33
33
|
.CodeMirror-gutters {
|
|
34
|
-
@apply border-gray-300 bg-
|
|
34
|
+
@apply border-gray-300 bg-gray-50 dark:border-gray-600 dark:bg-gray-700;
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
.CodeMirror-linenumber {
|
|
@@ -44,11 +44,11 @@
|
|
|
44
44
|
|
|
45
45
|
/* Toolbar theming */
|
|
46
46
|
.editor-toolbar {
|
|
47
|
-
@apply border-gray-300 bg-
|
|
47
|
+
@apply border-gray-300 bg-white dark:border-gray-600 dark:bg-gray-800;
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
.editor-toolbar.fullscreen {
|
|
51
|
-
@apply bg-
|
|
51
|
+
@apply bg-white dark:bg-gray-800;
|
|
52
52
|
}
|
|
53
53
|
|
|
54
54
|
.editor-toolbar button {
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
|
|
72
72
|
/* Preview theming */
|
|
73
73
|
.editor-preview {
|
|
74
|
-
@apply bg-
|
|
74
|
+
@apply bg-gray-50 text-gray-900 dark:bg-gray-800 dark:text-gray-100;
|
|
75
75
|
}
|
|
76
76
|
|
|
77
77
|
.editor-preview pre {
|
|
@@ -84,7 +84,7 @@
|
|
|
84
84
|
}
|
|
85
85
|
|
|
86
86
|
.editor-preview-side {
|
|
87
|
-
@apply border-gray-300 bg-
|
|
87
|
+
@apply border-gray-300 bg-white dark:border-gray-600 dark:bg-gray-800;
|
|
88
88
|
}
|
|
89
89
|
|
|
90
90
|
/* CodeMirror syntax highlighting - dark mode support */
|
|
@@ -127,11 +127,11 @@
|
|
|
127
127
|
|
|
128
128
|
/* Dropdown theming */
|
|
129
129
|
.editor-toolbar .easymde-dropdown {
|
|
130
|
-
@apply bg-
|
|
130
|
+
@apply bg-white border-gray-300 dark:bg-gray-800 dark:border-gray-600;
|
|
131
131
|
}
|
|
132
132
|
|
|
133
133
|
.easymde-dropdown-content {
|
|
134
|
-
@apply bg-
|
|
134
|
+
@apply bg-white shadow-lg border border-gray-200 dark:bg-gray-800 dark:border-gray-600 dark:shadow-gray-900/20;
|
|
135
135
|
}
|
|
136
136
|
|
|
137
137
|
.easymde-dropdown-content button {
|
data/src/css/intl_tel_input.css
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
--iti-hover-color: theme(colors.primary.50);
|
|
10
10
|
--iti-border-color: theme(colors.gray.300);
|
|
11
11
|
--iti-dialcode-color: theme(colors.gray.500);
|
|
12
|
-
--iti-dropdown-bg: theme(colors.
|
|
12
|
+
--iti-dropdown-bg: theme(colors.white);
|
|
13
13
|
--iti-arrow-color: theme(colors.gray.700);
|
|
14
14
|
}
|
|
15
15
|
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
--iti-hover-color: theme(colors.primary.900 / 0.3);
|
|
20
20
|
--iti-border-color: theme(colors.gray.600);
|
|
21
21
|
--iti-dialcode-color: theme(colors.gray.400);
|
|
22
|
-
--iti-dropdown-bg: theme(colors.
|
|
22
|
+
--iti-dropdown-bg: theme(colors.gray.700);
|
|
23
23
|
--iti-arrow-color: theme(colors.white);
|
|
24
24
|
}
|
|
25
25
|
}
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
--iti-hover-color: theme(colors.primary.900 / 0.3);
|
|
30
30
|
--iti-border-color: theme(colors.gray.600);
|
|
31
31
|
--iti-dialcode-color: theme(colors.gray.400);
|
|
32
|
-
--iti-dropdown-bg: theme(colors.
|
|
32
|
+
--iti-dropdown-bg: theme(colors.gray.700);
|
|
33
33
|
--iti-arrow-color: theme(colors.white);
|
|
34
34
|
}
|
|
35
35
|
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
.iti input.iti__tel-input,
|
|
43
43
|
.iti input.iti__tel-input[type=tel],
|
|
44
44
|
.iti input.iti__tel-input[type=text] {
|
|
45
|
-
@apply w-full border border-gray-300 rounded shadow-sm font-medium text-sm bg-
|
|
45
|
+
@apply w-full border border-gray-300 rounded-md shadow-sm font-medium text-sm bg-white text-gray-700 outline-none transition-colors duration-200 focus:ring-2 focus:ring-primary-500 focus:border-primary-500 dark:bg-gray-700 dark:border-gray-600 dark:text-white dark:placeholder-gray-400;
|
|
46
46
|
padding: theme(spacing.2);
|
|
47
47
|
padding-left: 52px;
|
|
48
48
|
/* Space for country selector */
|
|
@@ -87,12 +87,12 @@
|
|
|
87
87
|
|
|
88
88
|
/* Dropdown content styling to match form theme */
|
|
89
89
|
.iti .iti__dropdown-content {
|
|
90
|
-
@apply border border-gray-300 bg-
|
|
90
|
+
@apply border border-gray-300 bg-white shadow-sm rounded-md dark:bg-gray-700 dark:border-gray-600;
|
|
91
91
|
}
|
|
92
92
|
|
|
93
93
|
/* Search input to match form theme */
|
|
94
94
|
.iti .iti__search-input {
|
|
95
|
-
@apply w-full p-2 border border-gray-300 rounded shadow-sm font-medium text-sm bg-
|
|
95
|
+
@apply w-full p-2 border border-gray-300 rounded-md shadow-sm font-medium text-sm bg-white text-gray-700 outline-none focus:ring-2 focus:ring-primary-500 focus:border-primary-500 dark:bg-gray-700 dark:border-gray-600 dark:text-white dark:placeholder-gray-400;
|
|
96
96
|
margin: theme(spacing.2);
|
|
97
97
|
width: calc(100% - theme(spacing.4));
|
|
98
98
|
}
|
|
@@ -186,7 +186,7 @@
|
|
|
186
186
|
}
|
|
187
187
|
|
|
188
188
|
.iti--fullscreen-popup .iti__dropdown-content {
|
|
189
|
-
@apply bg-
|
|
189
|
+
@apply bg-white dark:bg-gray-700;
|
|
190
190
|
}
|
|
191
191
|
|
|
192
192
|
.iti--fullscreen-popup .iti__country {
|
data/src/css/slim_select.css
CHANGED
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
|
|
37
37
|
/* Main container - Updated to match form input theme */
|
|
38
38
|
.ss-main {
|
|
39
|
-
@apply flex flex-row relative select-none w-full min-h-8 p-2 cursor-pointer border border-gray-300 rounded shadow-sm font-medium text-sm bg-
|
|
39
|
+
@apply flex flex-row relative select-none w-full min-h-8 p-2 cursor-pointer border border-gray-300 rounded-md shadow-sm font-medium text-sm bg-white text-gray-700 outline-none transition-colors duration-200 overflow-hidden focus:ring-2 focus:ring-primary-500 focus:border-primary-500 dark:bg-gray-700 dark:border-gray-600 dark:text-white dark:placeholder-gray-400;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
.ss-main.ss-disabled {
|
|
@@ -131,7 +131,7 @@
|
|
|
131
131
|
|
|
132
132
|
/* Content container - Updated to match shadow and borders */
|
|
133
133
|
.ss-content {
|
|
134
|
-
@apply absolute flex h-auto flex-col w-auto max-h-72 border border-gray-300 bg-
|
|
134
|
+
@apply absolute flex h-auto flex-col w-auto max-h-72 border border-gray-300 bg-white shadow-sm transition-all duration-200 opacity-0 z-[10000] overflow-hidden dark:bg-gray-700 dark:border-gray-600;
|
|
135
135
|
transform: scaleY(0);
|
|
136
136
|
transform-origin: top;
|
|
137
137
|
}
|
|
@@ -162,14 +162,14 @@
|
|
|
162
162
|
}
|
|
163
163
|
|
|
164
164
|
.ss-content .ss-search input {
|
|
165
|
-
@apply inline-flex flex-auto w-full min-w-0 p-2 m-0 border border-gray-300 rounded shadow-sm font-medium text-sm bg-
|
|
165
|
+
@apply inline-flex flex-auto w-full min-w-0 p-2 m-0 border border-gray-300 rounded-md shadow-sm font-medium text-sm bg-white outline-none text-left placeholder:text-gray-400 focus:ring-2 focus:ring-primary-500 focus:border-primary-500 dark:bg-gray-700 dark:border-gray-600 dark:text-white dark:placeholder-gray-400;
|
|
166
166
|
box-sizing: border-box;
|
|
167
167
|
font-size: inherit;
|
|
168
168
|
line-height: inherit;
|
|
169
169
|
}
|
|
170
170
|
|
|
171
171
|
.ss-content .ss-search .ss-addable {
|
|
172
|
-
@apply inline-flex justify-center items-center cursor-pointer flex-none h-auto ml-2 border border-gray-300 rounded shadow-sm dark:border-gray-600;
|
|
172
|
+
@apply inline-flex justify-center items-center cursor-pointer flex-none h-auto ml-2 border border-gray-300 rounded-md shadow-sm dark:border-gray-600;
|
|
173
173
|
}
|
|
174
174
|
|
|
175
175
|
.ss-content .ss-search .ss-addable svg {
|
|
@@ -202,7 +202,7 @@
|
|
|
202
202
|
|
|
203
203
|
/* Option groups - Updated colors */
|
|
204
204
|
.ss-content .ss-list .ss-optgroup .ss-optgroup-label {
|
|
205
|
-
@apply flex flex-row items-center justify-between p-2 bg-
|
|
205
|
+
@apply flex flex-row items-center justify-between p-2 bg-gray-50 dark:bg-gray-600;
|
|
206
206
|
}
|
|
207
207
|
|
|
208
208
|
.ss-content .ss-list .ss-optgroup .ss-optgroup-label .ss-optgroup-label-text {
|
data/tailwind.options.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export const content = [
|
|
2
|
+
`${__dirname}/src/css/**/*.css`,
|
|
2
3
|
`${__dirname}/src/js/**/*.js`,
|
|
3
4
|
`${__dirname}/app/views/**/*.{rb,erb,js}`,
|
|
4
5
|
`${__dirname}/lib/plutonium/**/*.rb`,
|
|
@@ -63,36 +64,7 @@ export const theme = {
|
|
|
63
64
|
},
|
|
64
65
|
},
|
|
65
66
|
}),
|
|
66
|
-
// Semantic spacing scale - affects padding, margin, gap, space utilities
|
|
67
|
-
spacing: {
|
|
68
|
-
'xs': '0.5rem', // 8px - extra small spacing
|
|
69
|
-
'sm': '0.75rem', // 12px - small spacing (inputs, buttons, small gaps)
|
|
70
|
-
'md': '1rem', // 16px - medium spacing (cards, tabs, standard gaps)
|
|
71
|
-
'lg': '1.5rem', // 24px - large spacing (forms, displays, large spacing)
|
|
72
|
-
'xl': '2rem', // 32px - extra large spacing
|
|
73
|
-
'2xl': '2.5rem', // 40px - 2x extra large spacing
|
|
74
|
-
'3xl': '3rem', // 48px - 3x extra large spacing
|
|
75
|
-
},
|
|
76
67
|
colors: {
|
|
77
|
-
// Semantic background colors for theming - minimal, modern palette
|
|
78
|
-
surface: {
|
|
79
|
-
DEFAULT: '#ffffff', // Light mode surface (cards, forms, tables, panels)
|
|
80
|
-
dark: '#1f2937', // Dark mode surface - gray-800
|
|
81
|
-
},
|
|
82
|
-
page: {
|
|
83
|
-
DEFAULT: 'rgb(248 248 248)', // Light mode page - neutral gray
|
|
84
|
-
dark: '#111827', // Dark mode page - gray-900
|
|
85
|
-
},
|
|
86
|
-
elevated: {
|
|
87
|
-
DEFAULT: 'rgb(244 244 245)', // Light mode elevated - subtle
|
|
88
|
-
dark: '#374151', // Dark mode elevated - gray-700
|
|
89
|
-
},
|
|
90
|
-
interactive: {
|
|
91
|
-
DEFAULT: 'rgb(244 244 245)', // Light mode hover - subtle
|
|
92
|
-
dark: '#374151', // Dark mode hover - gray-700
|
|
93
|
-
},
|
|
94
|
-
|
|
95
|
-
// Brand colors
|
|
96
68
|
primary: {
|
|
97
69
|
50: '#F0FDFD',
|
|
98
70
|
100: '#E0FAFA',
|
|
@@ -234,7 +206,7 @@ export const theme = {
|
|
|
234
206
|
'Courier New',
|
|
235
207
|
'monospace'
|
|
236
208
|
]
|
|
237
|
-
}
|
|
209
|
+
}
|
|
238
210
|
};
|
|
239
211
|
|
|
240
212
|
export const safelist = [
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: plutonium
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.33.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Stefan Froelich
|
|
@@ -505,7 +505,6 @@ files:
|
|
|
505
505
|
- docs/guide/index.md
|
|
506
506
|
- docs/guide/introduction/01-what-is-plutonium.md
|
|
507
507
|
- docs/guide/introduction/02-core-concepts.md
|
|
508
|
-
- docs/guide/theming.md
|
|
509
508
|
- docs/guide/tutorial/01-project-setup.md
|
|
510
509
|
- docs/guide/tutorial/02-creating-a-feature-package.md
|
|
511
510
|
- docs/guide/tutorial/03-defining-resources.md
|
|
@@ -831,7 +830,6 @@ files:
|
|
|
831
830
|
- lib/plutonium/ui/component/behaviour.rb
|
|
832
831
|
- lib/plutonium/ui/component/kit.rb
|
|
833
832
|
- lib/plutonium/ui/component/methods.rb
|
|
834
|
-
- lib/plutonium/ui/component/theme.rb
|
|
835
833
|
- lib/plutonium/ui/component/tokens.rb
|
|
836
834
|
- lib/plutonium/ui/display/base.rb
|
|
837
835
|
- lib/plutonium/ui/display/components/association.rb
|