plutonium 0.32.0 → 0.33.1

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.
Files changed (50) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +10 -0
  3. data/app/assets/plutonium.css +2 -2
  4. data/lib/plutonium/resource/controllers/crud_actions.rb +21 -18
  5. data/lib/plutonium/resource/controllers/interactive_actions.rb +21 -25
  6. data/lib/plutonium/ui/action_button.rb +5 -11
  7. data/lib/plutonium/ui/block.rb +1 -4
  8. data/lib/plutonium/ui/breadcrumbs.rb +8 -10
  9. data/lib/plutonium/ui/color_mode_selector.rb +2 -2
  10. data/lib/plutonium/ui/component/behaviour.rb +0 -8
  11. data/lib/plutonium/ui/component/kit.rb +1 -1
  12. data/lib/plutonium/ui/display/components/attachment.rb +2 -2
  13. data/lib/plutonium/ui/display/theme.rb +16 -16
  14. data/lib/plutonium/ui/empty_card.rb +2 -5
  15. data/lib/plutonium/ui/form/components/key_value_store.rb +11 -11
  16. data/lib/plutonium/ui/form/components/secure_association.rb +2 -2
  17. data/lib/plutonium/ui/form/components/uppy.rb +5 -5
  18. data/lib/plutonium/ui/form/concerns/renders_nested_resource_fields.rb +5 -5
  19. data/lib/plutonium/ui/form/query.rb +11 -11
  20. data/lib/plutonium/ui/form/resource.rb +2 -2
  21. data/lib/plutonium/ui/form/theme.rb +17 -17
  22. data/lib/plutonium/ui/layout/base.rb +2 -2
  23. data/lib/plutonium/ui/layout/header.rb +7 -10
  24. data/lib/plutonium/ui/layout/rodauth_layout.rb +5 -5
  25. data/lib/plutonium/ui/layout/sidebar.rb +2 -2
  26. data/lib/plutonium/ui/nav_grid_menu.rb +6 -6
  27. data/lib/plutonium/ui/nav_user.rb +7 -8
  28. data/lib/plutonium/ui/page/interactive_action.rb +4 -4
  29. data/lib/plutonium/ui/page_header.rb +4 -7
  30. data/lib/plutonium/ui/panel.rb +3 -3
  31. data/lib/plutonium/ui/sidebar_menu.rb +12 -12
  32. data/lib/plutonium/ui/skeleton_table.rb +8 -8
  33. data/lib/plutonium/ui/tab_list.rb +3 -5
  34. data/lib/plutonium/ui/table/components/attachment.rb +2 -2
  35. data/lib/plutonium/ui/table/components/pagy_info.rb +3 -3
  36. data/lib/plutonium/ui/table/components/pagy_pagination.rb +3 -3
  37. data/lib/plutonium/ui/table/components/scopes_bar.rb +14 -14
  38. data/lib/plutonium/ui/table/display_theme.rb +3 -3
  39. data/lib/plutonium/ui/table/resource.rb +2 -2
  40. data/lib/plutonium/ui/table/theme.rb +13 -13
  41. data/lib/plutonium/version.rb +1 -1
  42. data/package.json +1 -1
  43. data/src/css/core.css +2 -2
  44. data/src/css/easymde.css +8 -8
  45. data/src/css/intl_tel_input.css +7 -7
  46. data/src/css/slim_select.css +5 -5
  47. data/tailwind.options.js +2 -30
  48. metadata +2 -4
  49. data/docs/guide/theming.md +0 -431
  50. data/lib/plutonium/ui/component/theme.rb +0 -47
@@ -12,7 +12,7 @@ module Plutonium
12
12
  end
13
13
 
14
14
  def view_template
15
- nav(aria_label: "Page navigation", class: "flex justify-center mt-md") do
15
+ nav(aria_label: "Page navigation", class: "flex justify-center mt-4") do
16
16
  ul(class: "inline-flex -space-x-px text-sm") do
17
17
  prev_link
18
18
  page_links
@@ -79,14 +79,14 @@ module Plutonium
79
79
  end
80
80
 
81
81
  def link_classes(first = false, last = false)
82
- classes = ["flex", "items-center", "justify-center", "px-sm", "h-8", "leading-tight", "text-gray-500", "bg-white", "border", "border-gray-300", "hover:bg-gray-100", "hover:text-gray-700", "dark:bg-gray-800", "dark:border-gray-700", "dark:text-gray-400", "dark:hover:bg-gray-700", "dark:hover:text-white"]
82
+ classes = ["flex", "items-center", "justify-center", "px-3", "h-8", "leading-tight", "text-gray-500", "bg-white", "border", "border-gray-300", "hover:bg-gray-100", "hover:text-gray-700", "dark:bg-gray-800", "dark:border-gray-700", "dark:text-gray-400", "dark:hover:bg-gray-700", "dark:hover:text-white"]
83
83
  classes << "rounded-s-lg" if first
84
84
  classes << "rounded-e-lg" if last
85
85
  classes.join(" ")
86
86
  end
87
87
 
88
88
  def current_link_classes
89
- "flex items-center justify-center px-sm h-8 text-blue-600 border border-gray-300 bg-blue-50 hover:bg-blue-100 hover:text-blue-700 dark:border-gray-700 dark:bg-gray-700 dark:text-white cursor-not-allowed"
89
+ "flex items-center justify-center px-3 h-8 text-blue-600 border border-gray-300 bg-blue-50 hover:bg-blue-100 hover:text-blue-700 dark:border-gray-700 dark:bg-gray-700 dark:text-white cursor-not-allowed"
90
90
  end
91
91
 
92
92
  def disabled_link_classes(first = false, last = false)
@@ -10,24 +10,24 @@ module Plutonium
10
10
  def view_template
11
11
  div(
12
12
  class:
13
- # "flex flex-wrap justify-between items-center gap-md p-md bg-white border border-gray-200 rounded-sm dark:bg-gray-800 dark:border-gray-700 mb-md"
14
- "flex flex-wrap justify-between items-center gap-md mb-md"
13
+ # "flex flex-wrap justify-between items-center gap-4 p-4 bg-white border border-gray-200 rounded-lg dark:bg-gray-800 dark:border-gray-700 mb-4"
14
+ "flex flex-wrap justify-between items-center gap-4 mb-4"
15
15
  ) do
16
- div(class: "flex flex-wrap items-center gap-sm") do
16
+ div(class: "flex flex-wrap items-center gap-2") do
17
17
  name = "all"
18
18
  if current_scope.blank?
19
19
  a(
20
20
  id: "#{name}-scope",
21
21
  href: current_query_object.build_url(scope: nil),
22
22
  class:
23
- "px-md py-sm text-sm font-medium text-white bg-primary-700 border border-primary-700 rounded-sm hover:bg-primary-800 focus:z-10 focus:ring-2 focus:ring-primary-700 focus:text-white dark:bg-primary-600 dark:border-primary-600 dark:hover:bg-primary-700 dark:focus:ring-primary-800"
23
+ "px-4 py-2 text-sm font-medium text-white bg-primary-700 border border-primary-700 rounded-lg hover:bg-primary-800 focus:z-10 focus:ring-2 focus:ring-primary-700 focus:text-white dark:bg-primary-600 dark:border-primary-600 dark:hover:bg-primary-700 dark:focus:ring-primary-800"
24
24
  ) { name.humanize }
25
25
  else
26
26
  a(
27
27
  id: "#{name}-scope",
28
28
  href: current_query_object.build_url(scope: nil),
29
29
  class:
30
- "px-md py-sm text-sm font-medium text-gray-500 bg-white border border-gray-300 rounded-sm hover:bg-gray-100 hover:text-gray-700 focus:z-10 focus:ring-2 focus:ring-gray-300 focus:text-gray-700 dark:bg-gray-800 dark:text-gray-400 dark:border-gray-600 dark:hover:text-white dark:hover:bg-gray-700 dark:focus:ring-gray-700 dark:focus:text-white"
30
+ "px-4 py-2 text-sm font-medium text-gray-500 bg-white border border-gray-300 rounded-lg hover:bg-gray-100 hover:text-gray-700 focus:z-10 focus:ring-2 focus:ring-gray-300 focus:text-gray-700 dark:bg-gray-800 dark:text-gray-400 dark:border-gray-600 dark:hover:text-white dark:hover:bg-gray-700 dark:focus:ring-gray-700 dark:focus:text-white"
31
31
  ) { name.humanize }
32
32
  end
33
33
 
@@ -37,26 +37,26 @@ module Plutonium
37
37
  id: "#{name}-scope",
38
38
  href: current_query_object.build_url(scope: name),
39
39
  class:
40
- "px-md py-sm text-sm font-medium text-white bg-primary-700 border border-primary-700 rounded-sm hover:bg-primary-800 focus:z-10 focus:ring-2 focus:ring-primary-700 focus:text-white dark:bg-primary-600 dark:border-primary-600 dark:hover:bg-primary-700 dark:focus:ring-primary-800"
40
+ "px-4 py-2 text-sm font-medium text-white bg-primary-700 border border-primary-700 rounded-lg hover:bg-primary-800 focus:z-10 focus:ring-2 focus:ring-primary-700 focus:text-white dark:bg-primary-600 dark:border-primary-600 dark:hover:bg-primary-700 dark:focus:ring-primary-800"
41
41
  ) { name.humanize }
42
42
  else
43
43
  a(
44
44
  id: "#{name}-scope",
45
45
  href: current_query_object.build_url(scope: name),
46
46
  class:
47
- "px-md py-sm text-sm font-medium text-gray-500 bg-white border border-gray-300 rounded-sm hover:bg-gray-100 hover:text-gray-700 focus:z-10 focus:ring-2 focus:ring-gray-300 focus:text-gray-700 dark:bg-gray-800 dark:text-gray-400 dark:border-gray-600 dark:hover:text-white dark:hover:bg-gray-700 dark:focus:ring-gray-700 dark:focus:text-white"
47
+ "px-4 py-2 text-sm font-medium text-gray-500 bg-white border border-gray-300 rounded-lg hover:bg-gray-100 hover:text-gray-700 focus:z-10 focus:ring-2 focus:ring-gray-300 focus:text-gray-700 dark:bg-gray-800 dark:text-gray-400 dark:border-gray-600 dark:hover:text-white dark:hover:bg-gray-700 dark:focus:ring-gray-700 dark:focus:text-white"
48
48
  ) { name.humanize }
49
49
  end
50
50
  end
51
51
  end
52
52
 
53
- # div(class: "flex flex-wrap items-center gap-sm") do
53
+ # div(class: "flex flex-wrap items-center gap-2") do
54
54
  # button(
55
55
  # class:
56
- # "inline-flex items-center px-sm py-sm text-sm font-medium text-white bg-red-700 rounded-sm hover:bg-red-800 focus:ring-4 focus:outline-none focus:ring-red-300 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-800"
56
+ # "inline-flex items-center px-3 py-2 text-sm font-medium text-white bg-red-700 rounded-lg hover:bg-red-800 focus:ring-4 focus:outline-none focus:ring-red-300 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-800"
57
57
  # ) do
58
58
  # svg(
59
- # class: "w-4 h-4 mr-sm",
59
+ # class: "w-4 h-4 mr-2",
60
60
  # fill: "none",
61
61
  # stroke: "currentColor",
62
62
  # viewbox: "0 0 24 24",
@@ -74,10 +74,10 @@ module Plutonium
74
74
  # end
75
75
  # button(
76
76
  # class:
77
- # "inline-flex items-center px-sm py-sm text-sm font-medium text-white bg-yellow-700 rounded-sm hover:bg-yellow-800 focus:ring-4 focus:outline-none focus:ring-yellow-300 dark:bg-yellow-600 dark:hover:bg-yellow-700 dark:focus:ring-yellow-800"
77
+ # "inline-flex items-center px-3 py-2 text-sm font-medium text-white bg-yellow-700 rounded-lg hover:bg-yellow-800 focus:ring-4 focus:outline-none focus:ring-yellow-300 dark:bg-yellow-600 dark:hover:bg-yellow-700 dark:focus:ring-yellow-800"
78
78
  # ) do
79
79
  # svg(
80
- # class: "w-4 h-4 mr-sm",
80
+ # class: "w-4 h-4 mr-2",
81
81
  # fill: "none",
82
82
  # stroke: "currentColor",
83
83
  # viewbox: "0 0 24 24",
@@ -97,13 +97,13 @@ module Plutonium
97
97
  # id: "dropdownActionButton",
98
98
  # data_dropdown_toggle: "dropdownAction",
99
99
  # class:
100
- # "inline-flex items-center text-gray-500 bg-white border border-gray-300 focus:outline-none hover:bg-gray-100 focus:ring-4 focus:ring-gray-200 font-medium rounded-sm text-sm px-sm py-sm dark:bg-gray-800 dark:text-gray-400 dark:border-gray-600 dark:hover:bg-gray-700 dark:hover:border-gray-600 dark:focus:ring-gray-700",
100
+ # "inline-flex items-center text-gray-500 bg-white border border-gray-300 focus:outline-none hover:bg-gray-100 focus:ring-4 focus:ring-gray-200 font-medium rounded-lg text-sm px-3 py-2 dark:bg-gray-800 dark:text-gray-400 dark:border-gray-600 dark:hover:bg-gray-700 dark:hover:border-gray-600 dark:focus:ring-gray-700",
101
101
  # type: "button"
102
102
  # ) do
103
103
  # span(class: "sr-only") { "Action button" }
104
104
  # plain " More Actions "
105
105
  # svg(
106
- # class: "w-2.5 h-2.5 ml-sm",
106
+ # class: "w-2.5 h-2.5 ml-2.5",
107
107
  # aria_hidden: "true",
108
108
  # xmlns: "http://www.w3.org/2000/svg",
109
109
  # fill: "none",
@@ -7,14 +7,14 @@ module Plutonium
7
7
  def self.theme
8
8
  super.merge({
9
9
  value_wrapper: "max-h-[150px] overflow-y-auto",
10
- prefixed_icon: "w-4 h-4 mr-xs",
10
+ prefixed_icon: "w-4 h-4 mr-1",
11
11
  link: "text-primary-600 dark:text-primary-500",
12
12
  color: "flex items-center",
13
- color_indicator: "w-10 h-10 rounded-full mr-sm",
13
+ color_indicator: "w-10 h-10 rounded-full mr-2",
14
14
  email: "flex items-center text-primary-600 dark:text-primary-500 whitespace-nowrap",
15
15
  phone: "flex items-center text-primary-600 dark:text-primary-500 whitespace-nowrap",
16
16
  json: " whitespace-pre font-mono shadow-inner p-4",
17
- attachment_value_wrapper: "flex flex-wrap gap-xs"
17
+ attachment_value_wrapper: "flex flex-wrap gap-1"
18
18
  })
19
19
  end
20
20
  end
@@ -91,7 +91,7 @@ module Plutonium
91
91
  record = wrapped_object.unwrapped
92
92
  policy = policy_for(record:)
93
93
 
94
- div(class: "flex space-x-sm") do
94
+ div(class: "flex space-x-2") do
95
95
  resource_definition.defined_actions
96
96
  .select { |k, a| a.collection_record_action? && policy.allowed_to?(:"#{k}?") }
97
97
  .values
@@ -105,7 +105,7 @@ module Plutonium
105
105
  end
106
106
 
107
107
  def render_footer
108
- div(class: tokens(theme_class(:table, element: :footer), "lg:sticky lg:dyna:static bottom-[-2px] mt-xs p-md pb-lg w-full z-30 bg-page dark:bg-page-dark")) {
108
+ div(class: "lg:sticky lg:dyna:static bottom-[-2px] mt-1 p-4 pb-6 w-full z-30 bg-gray-50 dark:bg-gray-900") {
109
109
  TableInfo(pagy_instance)
110
110
  TablePagination(pagy_instance)
111
111
  }
@@ -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-elevated-dark dark:border-gray-600",
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: "pu-table-wrapper relative overflow-x-auto shadow-md sm:rounded-sm",
14
- base: "pu-table w-full text-sm text-left rtl:text-right text-gray-500 dark:text-gray-400",
15
- caption: "p-md text-lg font-semibold text-left rtl:text-right text-gray-900 bg-surface dark:text-white dark:bg-surface-dark",
16
- description: "mt-xs text-sm font-normal text-gray-500 dark:text-gray-400",
17
- header: "pu-table-header text-xs text-gray-700 uppercase bg-elevated dark:bg-elevated-dark dark:text-gray-400",
18
- header_grouping_cell: "px-lg py-sm text-center text-sm border-b border-t border-r last:border-r-0 dark:border-gray-800",
19
- header_cell: "pu-table-header-cell px-lg py-sm",
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-xs.5",
23
- body_row: "pu-table-row bg-surface border-b last:border-none dark:bg-surface-dark dark:border-gray-700",
24
- body_cell: "pu-table-cell px-lg py-md whitespace-pre max-w-[450px] overflow-hidden text-ellipsis transition-all duration-300 ease-in-out",
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-sm",
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-xs text-red-600"
30
+ sort_index_clear_link_icon: "ml-1 text-red-600"
31
31
  })
32
32
  end
33
33
  end
@@ -1,5 +1,5 @@
1
1
  module Plutonium
2
- VERSION = "0.32.0"
2
+ VERSION = "0.33.1"
3
3
  NEXT_MAJOR_VERSION = VERSION.split(".").tap { |v|
4
4
  v[1] = v[1].to_i + 1
5
5
  v[2] = 0
data/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@radioactive-labs/plutonium",
3
- "version": "0.32.0",
3
+ "version": "0.33.1",
4
4
  "description": "Core assets for the Plutonium gem",
5
5
  "type": "module",
6
6
  "main": "src/js/core.js",
data/src/css/core.css CHANGED
@@ -8,9 +8,9 @@
8
8
  }
9
9
 
10
10
  .pu-color-input::-webkit-color-swatch {
11
- @apply border-none rounded-sm;
11
+ @apply border-none rounded-lg;
12
12
  }
13
13
 
14
14
  .pu-color-input::-moz-color-swatch {
15
- @apply border-none rounded-sm;
15
+ @apply border-none rounded-lg;
16
16
  }
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-surface text-gray-900 dark:border-gray-600 dark:bg-surface-dark dark:text-gray-100;
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-elevated dark:border-gray-600 dark:bg-elevated-dark;
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-surface dark:border-gray-600 dark:bg-surface-dark;
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-surface dark:bg-surface-dark;
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-elevated text-gray-900 dark:bg-surface-dark dark:text-gray-100;
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-surface dark:border-gray-600 dark:bg-surface-dark;
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-surface border-gray-300 dark:bg-surface-dark dark:border-gray-600;
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-surface shadow-lg border border-gray-200 dark:bg-surface-dark dark:border-gray-600 dark:shadow-gray-900/20;
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 {
@@ -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.surface.DEFAULT);
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.surface.dark);
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.surface.dark);
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-surface text-gray-700 outline-none transition-colors duration-200 focus:ring-2 focus:ring-primary-500 focus:border-primary-500 dark:bg-elevated-dark dark:border-gray-600 dark:text-white dark:placeholder-gray-400;
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-surface shadow-sm rounded dark:bg-surface-dark dark:border-gray-600;
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-surface text-gray-700 outline-none focus:ring-2 focus:ring-primary-500 focus:border-primary-500 dark:bg-elevated-dark dark:border-gray-600 dark:text-white dark:placeholder-gray-400;
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-surface dark:bg-surface-dark;
189
+ @apply bg-white dark:bg-gray-700;
190
190
  }
191
191
 
192
192
  .iti--fullscreen-popup .iti__country {
@@ -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-surface text-gray-700 outline-none transition-colors duration-200 overflow-hidden focus:ring-2 focus:ring-primary-500 focus:border-primary-500 dark:bg-elevated-dark dark:border-gray-600 dark:text-white dark:placeholder-gray-400;
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-surface shadow-sm transition-all duration-200 opacity-0 z-[10000] overflow-hidden dark:bg-surface-dark dark:border-gray-600;
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-surface outline-none text-left placeholder:text-gray-400 focus:ring-2 focus:ring-primary-500 focus:border-primary-500 dark:bg-elevated-dark dark:border-gray-600 dark:text-white dark:placeholder-gray-400;
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-elevated dark:bg-elevated-dark;
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,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: plutonium
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.32.0
4
+ version: 0.33.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stefan Froelich
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2026-01-12 00:00:00.000000000 Z
11
+ date: 2026-01-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: zeitwerk
@@ -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