avo 3.17.0 → 3.17.1.tw4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +1 -0
- data/app/assets/stylesheets/avo.base.css +6 -14
- data/app/assets/stylesheets/css/fields/progress.css +4 -4
- data/app/assets/stylesheets/css/fields/tiptap.css +4 -4
- data/app/assets/stylesheets/css/pagination.css +2 -2
- data/app/assets/stylesheets/css/search.css +4 -4
- data/app/assets/stylesheets/css/tooltips.css +1 -1
- data/app/components/avo/actions_component.html.erb +3 -3
- data/app/components/avo/alert_component.html.erb +2 -2
- data/app/components/avo/alert_component.rb +1 -1
- data/app/components/avo/backtrace_alert_component.html.erb +3 -3
- data/app/components/avo/button_component.rb +3 -3
- data/app/components/avo/divider_component.html.erb +2 -2
- data/app/components/avo/empty_state_component.html.erb +1 -1
- data/app/components/avo/field_wrapper_component.html.erb +1 -1
- data/app/components/avo/fields/belongs_to_field/edit_component.html.erb +1 -1
- data/app/components/avo/fields/boolean_field/edit_component.html.erb +1 -1
- data/app/components/avo/fields/boolean_group_field/edit_component.rb +1 -1
- data/app/components/avo/fields/common/files/view_type/list_item_component.html.erb +3 -3
- data/app/components/avo/fields/common/key_value_component.html.erb +3 -3
- data/app/components/avo/fields/common/status_viewer_component.html.erb +6 -5
- data/app/components/avo/fields/date_field/edit_component.html.erb +1 -1
- data/app/components/avo/fields/date_time_field/edit_component.html.erb +1 -1
- data/app/components/avo/fields/tags_field/edit_component.html.erb +1 -1
- data/app/components/avo/fields/tags_field/tag_component.html.erb +1 -1
- data/app/components/avo/fields/tiptap_field/edit_component.html.erb +1 -1
- data/app/components/avo/fields/trix_field/edit_component.html.erb +1 -1
- data/app/components/avo/filters_component.html.erb +3 -3
- data/app/components/avo/index/grid_item_component.html.erb +2 -2
- data/app/components/avo/index/grid_item_component.rb +1 -1
- data/app/components/avo/index/resource_grid_component.html.erb +1 -1
- data/app/components/avo/index/resource_map_component.html.erb +1 -1
- data/app/components/avo/index/resource_table_component.html.erb +1 -1
- data/app/components/avo/index/table_row_component.html.erb +3 -3
- data/app/components/avo/items/panel_component.html.erb +1 -1
- data/app/components/avo/media_library/item_details_component.html.erb +1 -1
- data/app/components/avo/modal_component.html.erb +1 -1
- data/app/components/avo/paginator_component.html.erb +1 -2
- data/app/components/avo/panel_component.html.erb +2 -2
- data/app/components/avo/profile_item_component.rb +1 -1
- data/app/components/avo/resource_sidebar_component.html.erb +1 -1
- data/app/components/avo/row_selector_component.html.erb +1 -1
- data/app/components/avo/sidebar/link_component.rb +1 -1
- data/app/components/avo/sidebar_component.html.erb +3 -3
- data/app/components/avo/sidebar_profile_component.html.erb +4 -4
- data/app/components/avo/tab_group_component.html.erb +1 -1
- data/app/helpers/avo/application_helper.rb +4 -4
- data/app/javascript/js/controllers/fields/key_value_controller.js +1 -1
- data/app/javascript/js/controllers/fields/tags_field_helpers.js +1 -1
- data/app/javascript/js/controllers/search_controller.js +2 -2
- data/app/views/avo/base/preview.html.erb +1 -1
- data/app/views/avo/debug/report.html.erb +1 -1
- data/app/views/avo/debug/status.html.erb +19 -14
- data/app/views/avo/home/_actions.html.erb +1 -1
- data/app/views/avo/home/_dashboards.html.erb +1 -1
- data/app/views/avo/home/_filters.html.erb +1 -1
- data/app/views/avo/home/_resources.html.erb +2 -2
- data/app/views/avo/home/failed_to_load.html.erb +1 -1
- data/app/views/avo/partials/_confirm_dialog.html.erb +4 -4
- data/app/views/avo/partials/_custom_tools_alert.html.erb +6 -6
- data/app/views/avo/partials/_navbar.html.erb +3 -3
- data/app/views/avo/partials/_resource_search.html.erb +1 -1
- data/app/views/avo/partials/_table_header.html.erb +2 -2
- data/app/views/avo/sidebar/_license_warning.html.erb +1 -1
- data/lib/avo/concerns/row_controls_configuration.rb +16 -15
- data/lib/avo/resources/items/holder.rb +1 -1
- data/lib/avo/version.rb +1 -1
- data/lib/generators/avo/resource_tool_generator.rb +1 -1
- data/lib/generators/avo/templates/cards/partial_card_partial.tt +1 -1
- data/lib/generators/avo/tool_generator.rb +2 -2
- data/lib/tasks/avo_tasks.rake +1 -1
- data/public/avo-assets/avo.base.css +7892 -9538
- data/public/avo-assets/avo.base.js +3 -3
- data/public/avo-assets/avo.base.js.map +2 -2
- metadata +3 -6
- data/app/assets/stylesheets/css/tailwindcss/base.css +0 -1
- data/app/assets/stylesheets/css/tailwindcss/components.css +0 -1
- data/app/assets/stylesheets/css/tailwindcss/utilities.css +0 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 739659797d530c1acdb0ec8bed1c2f86bc2b35eff7955aaeecac6926b82313d3
|
4
|
+
data.tar.gz: 5885212b7582e4dfe6e181a4e42040dfe5ea8bf11656b121f377b95209ab0a23
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0b6b20a4d328b54edbb9b6c22c8e73454f3d2015f73646020f8428134b85000823340a5b77cc214238343c60485f9b6bdfa249e3588545b69ef1a32e66590b96
|
7
|
+
data.tar.gz: 49e9aab89f78ebf948d85a39ce1fe536f7fadbfe650b69f5952cbdd7f97277ca7e691b8c016b24371477fc8174e3731e70e6ca57bf828cb1c48f869df9b3d231
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -125,5 +125,6 @@ Please read the [RELEASE.MD](./RELEASE.MD)
|
|
125
125
|
|
126
126
|
- [`active_storage-blurhash`](https://github.com/avo-hq/active_storage-blurhash) - A plug-n-play [blurhash](https://blurha.sh/) integration for images stored in ActiveStorage
|
127
127
|
- [`class_variants`](https://github.com/avo-hq/class_variants) - Easily configure styles and apply them as classes. Very useful when you're implementing Tailwind CSS components and call them with different states.
|
128
|
+
- [`marksmith`](https://github.com/avo-hq/marksmith) - GitHub-style markdown editor for Ruby on Rails with ActiveStorage support.
|
128
129
|
- [`prop_initializer`](https://github.com/avo-hq/prop_initializer) - A flexible tool for defining properties on Ruby classes.
|
129
130
|
- [`stimulus-confetti`](https://github.com/avo-hq/stimulus-confetti) - The easiest way to add confetti to your StimulusJS app
|
@@ -1,3 +1,9 @@
|
|
1
|
+
@import "tailwindcss";
|
2
|
+
|
3
|
+
@config "../../../tailwind.config.js";
|
4
|
+
|
5
|
+
|
6
|
+
|
1
7
|
@import './../../../node_modules/easymde/dist/easymde.min.css';
|
2
8
|
@import './../../../node_modules/tippy.js/dist/tippy.css';
|
3
9
|
@import './../../../node_modules/tippy.js/themes/light.css';
|
@@ -5,8 +11,6 @@
|
|
5
11
|
@import './../../../node_modules/@algolia/autocomplete-theme-classic/dist/theme.css';
|
6
12
|
@import './../../../node_modules/@yaireo/tagify/dist/tagify.css';
|
7
13
|
|
8
|
-
@import 'tailwindcss/base';
|
9
|
-
|
10
14
|
@import './css/fonts.css';
|
11
15
|
@import './css/buttons.css';
|
12
16
|
@import './css/typography.css';
|
@@ -27,10 +31,6 @@
|
|
27
31
|
@import './css/fields/tags.css';
|
28
32
|
@import './css/fields/tiptap.css';
|
29
33
|
|
30
|
-
@import 'tailwindcss/components';
|
31
|
-
|
32
|
-
@import 'tailwindcss/utilities';
|
33
|
-
|
34
34
|
html,
|
35
35
|
body {
|
36
36
|
@apply antialiased relative h-full;
|
@@ -105,14 +105,6 @@ dl {
|
|
105
105
|
}
|
106
106
|
}
|
107
107
|
|
108
|
-
/* TODO: make content like tailwindcss */
|
109
|
-
.floating-row-controls {
|
110
|
-
&:before {
|
111
|
-
content: "";
|
112
|
-
@apply absolute z-10 inset-auto left-0 top-0 mt-0 -translate-x-full w-3 h-full bg-gradient-to-l from-white to-transparent group-hover:from-gray-50;
|
113
|
-
}
|
114
|
-
}
|
115
|
-
|
116
108
|
.shift-pressed {
|
117
109
|
& .highlighted-row {
|
118
110
|
@apply !bg-neutral-200;
|
@@ -1,13 +1,13 @@
|
|
1
1
|
progress {
|
2
|
-
@apply h-2 bg-white border border-slate-400 rounded shadow-inner;
|
2
|
+
@apply h-2 bg-white border border-slate-400 rounded-sm shadow-inner;
|
3
3
|
}
|
4
4
|
progress[value]::-webkit-progress-bar {
|
5
|
-
@apply bg-white border border-gray-500 rounded shadow-inner;
|
5
|
+
@apply bg-white border border-gray-500 rounded-sm shadow-inner;
|
6
6
|
}
|
7
7
|
progress[value]::-webkit-progress-value{
|
8
|
-
@apply bg-primary-500 rounded;
|
8
|
+
@apply bg-primary-500 rounded-sm;
|
9
9
|
|
10
10
|
}
|
11
11
|
progress[value]::-moz-progress-bar {
|
12
|
-
@apply bg-primary-500 rounded appearance-none;
|
12
|
+
@apply bg-primary-500 rounded-sm appearance-none;
|
13
13
|
}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
/* EDIT STYLES */
|
2
2
|
|
3
3
|
.tiptap {
|
4
|
-
@apply m-0 p-4 outline-
|
4
|
+
@apply m-0 p-4 outline-hidden min-h-44;
|
5
5
|
|
6
6
|
>*+* {
|
7
7
|
@apply mt-4;
|
@@ -22,7 +22,7 @@
|
|
22
22
|
}
|
23
23
|
|
24
24
|
.tiptap__field {
|
25
|
-
@apply w-full mb-4 border border-gray-200 rounded;
|
25
|
+
@apply w-full mb-4 border border-gray-200 rounded-sm;
|
26
26
|
}
|
27
27
|
|
28
28
|
.tiptap__editor {
|
@@ -54,7 +54,7 @@
|
|
54
54
|
}
|
55
55
|
|
56
56
|
.tiptap__button {
|
57
|
-
@apply p-1 text-gray-500 rounded cursor-pointer;
|
57
|
+
@apply p-1 text-gray-500 rounded-sm cursor-pointer;
|
58
58
|
|
59
59
|
&:hover:enabled {
|
60
60
|
@apply bg-gray-100;
|
@@ -94,7 +94,7 @@
|
|
94
94
|
}
|
95
95
|
|
96
96
|
.tiptap__link-field {
|
97
|
-
@apply text-sm mr-2 py-1 border border-gray-200 rounded;
|
97
|
+
@apply text-sm mr-2 py-1 border border-gray-200 rounded-sm;
|
98
98
|
}
|
99
99
|
|
100
100
|
/* SHOW STYLES */
|
@@ -22,7 +22,7 @@
|
|
22
22
|
.pagy-nav-js .page a,
|
23
23
|
.pagy-combo-nav-js .page a,
|
24
24
|
.pagy-combo-nav-js .pagy-combo-input a {
|
25
|
-
@apply rounded px-3 py-1 text-sm text-gray-500 font-semibold bg-white shadow-md border border-gray-300;
|
25
|
+
@apply rounded-sm px-3 py-1 text-sm text-gray-500 font-semibold bg-white shadow-md border border-gray-300;
|
26
26
|
|
27
27
|
&:hover{
|
28
28
|
@apply bg-gray-150;
|
@@ -73,7 +73,7 @@
|
|
73
73
|
}
|
74
74
|
|
75
75
|
& a:not(.gap) {
|
76
|
-
@apply block rounded px-3 py-1 text-sm text-gray-500 font-semibold bg-white shadow-md border border-gray-300;
|
76
|
+
@apply block rounded-sm px-3 py-1 text-sm text-gray-500 font-semibold bg-white shadow-md border border-gray-300;
|
77
77
|
|
78
78
|
&:hover{
|
79
79
|
@apply bg-gray-150;
|
@@ -22,7 +22,7 @@
|
|
22
22
|
}
|
23
23
|
|
24
24
|
.aa-DetachedSearchButton {
|
25
|
-
@apply rounded border-gray-300 h-[34px];
|
25
|
+
@apply rounded-sm border-gray-300 h-[34px];
|
26
26
|
}
|
27
27
|
}
|
28
28
|
|
@@ -37,11 +37,11 @@
|
|
37
37
|
|
38
38
|
.aa-Form {
|
39
39
|
&:focus-within {
|
40
|
-
@apply ring-0
|
40
|
+
@apply ring-0;
|
41
41
|
}
|
42
42
|
|
43
43
|
input {
|
44
|
-
@apply focus:ring-0
|
44
|
+
@apply focus:ring-0;
|
45
45
|
}
|
46
46
|
&:focus-within {
|
47
47
|
.aa-InputWrapperPrefix{
|
@@ -71,7 +71,7 @@ button.aa-DetachedCancelButton {
|
|
71
71
|
@apply space-y-2;
|
72
72
|
|
73
73
|
.aa-Item {
|
74
|
-
@apply bg-white rounded px-3 py-4 shadow font-medium;
|
74
|
+
@apply bg-white rounded-sm px-3 py-4 shadow font-medium;
|
75
75
|
|
76
76
|
.aa-ItemDescription {
|
77
77
|
@apply text-gray-500 text-sm font-normal mt-1;
|
@@ -10,7 +10,7 @@
|
|
10
10
|
type: :button,
|
11
11
|
color: @color,
|
12
12
|
size: @size,
|
13
|
-
class: "focus:outline-
|
13
|
+
class: "focus:outline-hidden",
|
14
14
|
icon: @icon,
|
15
15
|
data: {
|
16
16
|
action: "click->toggle#togglePanel",
|
@@ -21,7 +21,7 @@
|
|
21
21
|
<%= @label %>
|
22
22
|
<% end %>
|
23
23
|
<div
|
24
|
-
class="absolute flex inset-auto xl:right-0 top-full bg-white w-full sm:w-auto sm:min-w-[300px] mt-2 z-40 shadow-modal rounded overflow-hidden hidden"
|
24
|
+
class="absolute flex inset-auto xl:right-0 top-full bg-white w-full sm:w-auto sm:min-w-[300px] mt-2 z-40 shadow-modal rounded-sm overflow-hidden hidden"
|
25
25
|
data-toggle-target="panel"
|
26
26
|
data-controller="actions-overflow"
|
27
27
|
data-actions-overflow-panel-list-value="<%= !@as_row_control %>"
|
@@ -33,7 +33,7 @@
|
|
33
33
|
data-transition-leave-start="transform opacity-100 translate-y-0"
|
34
34
|
data-transition-leave-end="transform opacity-0 -translate-y-1"
|
35
35
|
>
|
36
|
-
<div data-target="actions-list" class="w-full space divide-y">
|
36
|
+
<div data-target="actions-list" class="w-full space divide-y divide-gray-200">
|
37
37
|
<% @actions.each do |action| %>
|
38
38
|
<%= render_item(action)%>
|
39
39
|
<% end %>
|
@@ -13,8 +13,8 @@
|
|
13
13
|
<%= sanitize @message.to_s %>
|
14
14
|
</p>
|
15
15
|
</div>
|
16
|
-
<div class="ml-4
|
17
|
-
<button data-action="alert#close" class="inline-flex text-white focus:outline-
|
16
|
+
<div class="ml-4 shrink-0 flex items-center">
|
17
|
+
<button data-action="alert#close" class="inline-flex text-white focus:outline-hidden focus:text-gray-300 transition ease-in-out duration-150">
|
18
18
|
<svg class="h-5 w-5" viewBox="0 0 20 20" fill="currentColor">
|
19
19
|
<path fill-rule="evenodd" d="M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z" clip-rule="evenodd"/>
|
20
20
|
</svg>
|
@@ -18,7 +18,7 @@ class Avo::AlertComponent < Avo::BaseComponent
|
|
18
18
|
def classes
|
19
19
|
return "hidden" if is_empty?
|
20
20
|
|
21
|
-
result = "max-w-lg w-full shadow-lg
|
21
|
+
result = "max-w-lg w-full shadow-lg px-4 py-3 rounded-sm relative border text-white pointer-events-auto"
|
22
22
|
|
23
23
|
result += if is_error?
|
24
24
|
" bg-red-400 border-red-600"
|
@@ -1,7 +1,7 @@
|
|
1
1
|
<div data-controller="alert"
|
2
2
|
data-alert-dismiss-after-value="<%= Avo.configuration.alert_dismiss_time %>"
|
3
3
|
data-alert-remove-delay-value="0"
|
4
|
-
class="w-full shadow-lg px-4 py-3 rounded relative border text-white pointer-events-auto bg-red-400 border-red-600"
|
4
|
+
class="w-full shadow-lg px-4 py-3 rounded-sm relative border text-white pointer-events-auto bg-red-400 border-red-600"
|
5
5
|
>
|
6
6
|
<div class="px-2">
|
7
7
|
<div class="flex h-full">
|
@@ -14,8 +14,8 @@
|
|
14
14
|
<pre class='overflow-y-scroll max-h-64 whitespace-pre-wrap text-xs'><%= @backtrace.join("\n") %></pre>
|
15
15
|
</p>
|
16
16
|
</div>
|
17
|
-
<div class="ml-4
|
18
|
-
<button data-action="alert#close" class="inline-flex text-white focus:outline-
|
17
|
+
<div class="ml-4 shrink-0 flex items-center">
|
18
|
+
<button data-action="alert#close" class="inline-flex text-white focus:outline-hidden focus:text-gray-300 transition ease-in-out duration-150">
|
19
19
|
<svg class="h-5 w-5" viewBox="0 0 20 20" fill="currentColor">
|
20
20
|
<path fill-rule="evenodd" d="M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z" clip-rule="evenodd"/>
|
21
21
|
</svg>
|
@@ -34,12 +34,12 @@ class Avo::ButtonComponent < Avo::BaseComponent
|
|
34
34
|
end
|
35
35
|
|
36
36
|
def button_classes
|
37
|
-
classes = "button-component inline-flex
|
37
|
+
classes = "button-component inline-flex grow-0 items-center font-semibold leading-6 fill-current whitespace-nowrap transition duration-100 transform transition duration-100 cursor-pointer disabled:cursor-not-allowed disabled:opacity-60 data-[disabled='true']:opacity-60 justify-center #{@class}"
|
38
38
|
|
39
39
|
# For non-icon-styled buttons we should not add borders.
|
40
|
-
classes += " border active:outline active:outline-1" unless is_icon?
|
40
|
+
classes += " border border-gray-200 active:outline active:outline-1" unless is_icon?
|
41
41
|
|
42
|
-
classes += " rounded" if @rounded.present?
|
42
|
+
classes += " rounded-sm" if @rounded.present?
|
43
43
|
classes += style_classes
|
44
44
|
classes += horizontal_padding_classes
|
45
45
|
classes += vertical_padding_classes
|
@@ -1,6 +1,6 @@
|
|
1
|
-
<div class="relative flex justify-center items-center w-full !border-b
|
1
|
+
<div class="relative flex justify-center items-center w-full !border-b border-gray-200 border-solid" data-component-name="<%= self.class.to_s.underscore %>">
|
2
2
|
<% if @label.present? %>
|
3
|
-
<div class="absolute inset-auto z-20 text-
|
3
|
+
<div class="absolute inset-auto z-20 text-[11px] font-semibold uppercase leading-none text-gray-500 bg-white border border-gray-200 px-2 py-1 rounded-sm">
|
4
4
|
<%= @label %>
|
5
5
|
</div>
|
6
6
|
<% end %>
|
@@ -1,5 +1,5 @@
|
|
1
1
|
<% if @add_background %>
|
2
|
-
<div class="bg-white rounded shadow-panel">
|
2
|
+
<div class="bg-white rounded-sm shadow-panel">
|
3
3
|
<% end %>
|
4
4
|
<div class="relative flex-1 flex flex-col items-center justify-center space-y-12 py-24">
|
5
5
|
<%= helpers.svg view_type_svg, class: 'h-[250px]' %>
|
@@ -2,7 +2,7 @@
|
|
2
2
|
class: classes,
|
3
3
|
style: style,
|
4
4
|
data: data do %>
|
5
|
-
<%= content_tag :div, class: class_names("pt-4 flex self-start items-center
|
5
|
+
<%= content_tag :div, class: class_names("pt-4 flex self-start items-center shrink-0 w-48 px-6 uppercase font-semibold text-gray-500 text-sm", @field.get_html(:classes, view: @view, element: :label), {
|
6
6
|
"md:pt-4 md:w-full": stacked?,
|
7
7
|
"h-full md:pt-0": !stacked?,
|
8
8
|
"md:h-10 ": !stacked? && short?,
|
@@ -3,7 +3,7 @@
|
|
3
3
|
<%= @form.check_box @field.id,
|
4
4
|
value: @field.value,
|
5
5
|
checked: @field.value,
|
6
|
-
class: "text-lg h-4 w-4 checked:bg-primary-400 focus:checked:!bg-primary-400 rounded #{@field.get_html(:classes, view: view, element: :input)}",
|
6
|
+
class: "text-lg h-4 w-4 checked:bg-primary-400 focus:checked:!bg-primary-400 rounded-sm #{@field.get_html(:classes, view: view, element: :input)}",
|
7
7
|
data: @field.get_html(:data, view: view, element: :input),
|
8
8
|
disabled: disabled?,
|
9
9
|
autofocus: @autofocus,
|
@@ -5,7 +5,7 @@ class Avo::Fields::BooleanGroupField::EditComponent < Avo::Fields::EditComponent
|
|
5
5
|
super(...)
|
6
6
|
|
7
7
|
# Initialize here to avoid multiple calls to @field.get_html for each option.
|
8
|
-
@classes = "w-4 h-4 rounded checked:bg-primary-400 focus:checked:!bg-primary-400" \
|
8
|
+
@classes = "w-4 h-4 rounded-sm checked:bg-primary-400 focus:checked:!bg-primary-400" \
|
9
9
|
"#{@field.get_html(:classes, view: view, element: :input)}"
|
10
10
|
@data = @field.get_html(:data, view: view, element: :input)
|
11
11
|
@style = @field.get_html(:style, view: view, element: :input)
|
@@ -5,14 +5,14 @@
|
|
5
5
|
<div class="rounded-full bg-slate-100 border border-gray-500 p-1.5 flex items-center justify-center">
|
6
6
|
<%= helpers.svg icon_for_file, class: "h-5 text-gray-600" %>
|
7
7
|
</div>
|
8
|
-
<p class="items-center h-full p-2
|
8
|
+
<p class="items-center h-full p-2 shrink-0">
|
9
9
|
<%= file.filename %>
|
10
10
|
</p>
|
11
11
|
</div>
|
12
|
-
<div class="text-gray-700
|
12
|
+
<div class="text-gray-700 shrink-0 text-sm">
|
13
13
|
<%= helpers.number_to_human_size(file.byte_size) %>
|
14
14
|
</div>
|
15
|
-
<div class="flex space-x-2 justify-end col-span-1
|
15
|
+
<div class="flex space-x-2 justify-end col-span-1 shrink-0">
|
16
16
|
<%= render Avo::Fields::Common::Files::ControlsComponent.new(field: @field, file: file, resource: @resource) %>
|
17
17
|
</div>
|
18
18
|
</div>
|
@@ -1,4 +1,4 @@
|
|
1
|
-
<div class="w-full shadow-lg rounded overflow-hidden"
|
1
|
+
<div class="w-full shadow-lg rounded-sm overflow-hidden"
|
2
2
|
data-controller="key-value"
|
3
3
|
data-key-value-target="controller"
|
4
4
|
data-options="<%= @field.options.to_json %>"
|
@@ -7,8 +7,8 @@
|
|
7
7
|
>
|
8
8
|
<div class="w-full flex flex-col">
|
9
9
|
<div class="flex w-full">
|
10
|
-
<div class="flex w-full bg-gray-700 shadow overflow-hidden">
|
11
|
-
<div class="w-1/2 py-3 px-3 uppercase font-semibold text-xs text-white border-gray-600 border-r">
|
10
|
+
<div class="flex w-full bg-gray-700 shadow-sm overflow-hidden">
|
11
|
+
<div class="w-1/2 py-3 px-3 uppercase font-semibold text-xs text-white border-gray-600 border-r border-gray-200">
|
12
12
|
<%= @field.key_label %>
|
13
13
|
</div>
|
14
14
|
<div class="w-1/2 py-3 px-3 uppercase font-semibold text-xs text-white">
|
@@ -1,10 +1,11 @@
|
|
1
1
|
<%
|
2
|
-
classes =
|
3
|
-
|
4
|
-
|
5
|
-
|
2
|
+
classes = class_names(
|
3
|
+
"text-red-600": @status == 'failed',
|
4
|
+
"text-green-600": @status == 'success',
|
5
|
+
"text-gray-600": @status == 'neutral'
|
6
|
+
)
|
6
7
|
%>
|
7
|
-
<div class="flex
|
8
|
+
<div class="flex shrink-0 <%= classes %> items-center">
|
8
9
|
<% if @status == 'success' %>
|
9
10
|
<%= helpers.svg 'heroicons/solid/check-circle', class: 'h-4' %>
|
10
11
|
<% elsif @status == 'failed' %>
|
@@ -12,7 +12,7 @@
|
|
12
12
|
} do %>
|
13
13
|
<%= @form.text_field @field.id,
|
14
14
|
value: @field.edit_formatted_value,
|
15
|
-
class: classes("w-full #{"hidden" unless params[:avo_show_hidden_inputs]}"),
|
15
|
+
class: classes("w-full #{"!hidden" unless params[:avo_show_hidden_inputs]}"),
|
16
16
|
data: {
|
17
17
|
'date-field-target': 'input',
|
18
18
|
placeholder: @field.placeholder,
|
@@ -14,7 +14,7 @@
|
|
14
14
|
} do %>
|
15
15
|
<%= @form.text_field @field.id,
|
16
16
|
value: @field.edit_formatted_value,
|
17
|
-
class: classes("w-full #{"hidden" unless params[:avo_show_hidden_inputs]}"),
|
17
|
+
class: classes("w-full #{"!hidden" unless params[:avo_show_hidden_inputs]}"),
|
18
18
|
data: {
|
19
19
|
date_field_target: :input,
|
20
20
|
placeholder: @field.placeholder,
|
@@ -23,7 +23,7 @@
|
|
23
23
|
%>
|
24
24
|
<%# real field %>
|
25
25
|
<%= @form.text_field @field.id,
|
26
|
-
class: classes("hidden w-full !py-0 min-h-10 items-center border-primary-500 focus-within:border-primary-500"),
|
26
|
+
class: classes("!hidden w-full !py-0 min-h-10 items-center border-primary-500 focus-within:border-primary-500"),
|
27
27
|
data: {
|
28
28
|
tags_field_target: :input,
|
29
29
|
},
|
@@ -14,7 +14,7 @@
|
|
14
14
|
<% end %>
|
15
15
|
<%= @form.text_area @field.id,
|
16
16
|
value: @field.value.try(:to_trix_html) || @field.value,
|
17
|
-
class: classes("w-full hidden"),
|
17
|
+
class: classes("w-full !hidden"),
|
18
18
|
data: @field.get_html(:data, view: view, element: :input),
|
19
19
|
disabled: disabled?,
|
20
20
|
id: @input_id,
|
@@ -1,6 +1,6 @@
|
|
1
1
|
<div data-controller="toggle" data-component-name="<%= self.class.to_s.underscore %>">
|
2
2
|
<div class="relative w-full flex justify-between">
|
3
|
-
<%= a_button class: 'focus:outline-
|
3
|
+
<%= a_button class: 'focus:outline-hidden',
|
4
4
|
color: :primary,
|
5
5
|
size: :sm,
|
6
6
|
icon: "avo/filter",
|
@@ -14,7 +14,7 @@
|
|
14
14
|
<% end %>
|
15
15
|
<% end %>
|
16
16
|
<div
|
17
|
-
class="absolute block inset-auto sm:right-0 top-full bg-white min-w-[300px] mt-2 z-40 shadow-modal rounded divide-y divide-gray-300 <%= 'hidden' unless params[:keep_filters_panel_open] == '1' %>"
|
17
|
+
class="absolute block inset-auto sm:right-0 top-full bg-white min-w-[300px] mt-2 z-40 shadow-modal rounded-sm divide-y divide-gray-300 <%= 'hidden' unless params[:keep_filters_panel_open] == '1' %>"
|
18
18
|
data-toggle-target="panel"
|
19
19
|
data-transition-enter="transition ease-out duration-100"
|
20
20
|
data-transition-enter-start="transform opacity-0 -translate-y-1"
|
@@ -26,7 +26,7 @@
|
|
26
26
|
<% @filters.each do |filter| %>
|
27
27
|
<%= render partial: filter.class.template, locals: {filter: filter} %>
|
28
28
|
<% end %>
|
29
|
-
<div class="p-4 border-gray-
|
29
|
+
<div class="p-4 border-gray-200 border-t">
|
30
30
|
<% if @applied_filters.present? %>
|
31
31
|
<%= a_link reset_path, data: {turbo_frame: params[:turbo_frame]}, color: :gray, size: :sm, class: 'w-full justify-center' do %>
|
32
32
|
<%= t('avo.reset_filters') %>
|
@@ -1,5 +1,5 @@
|
|
1
1
|
<%= content_tag :div,
|
2
|
-
class: "relative bg-white rounded shadow-modal flex flex-col group",
|
2
|
+
class: "relative bg-white rounded-sm shadow-modal flex flex-col group",
|
3
3
|
data: {
|
4
4
|
component_name: self.class.to_s.underscore,
|
5
5
|
resource_name: @resource.class.to_s,
|
@@ -8,7 +8,7 @@
|
|
8
8
|
**(try(:drag_reorder_item_data_attributes) || {}),
|
9
9
|
} do %>
|
10
10
|
<%= content_tag :div,
|
11
|
-
class: class_names("relative w-full pb-3/4 rounded-t overflow-hidden", html(:cover, :classes)),
|
11
|
+
class: class_names("relative w-full pb-3/4 rounded-t-sm overflow-hidden", html(:cover, :classes)),
|
12
12
|
style: html(:cover, :style) do %>
|
13
13
|
<%= render Avo::RowSelectorComponent.new(floating: true, size: :lg) if @resource.record_selector%>
|
14
14
|
<%= render_cover %>
|
@@ -70,7 +70,7 @@ class Avo::Index::GridItemComponent < Avo::BaseComponent
|
|
70
70
|
return if @card[:badge_label].blank?
|
71
71
|
|
72
72
|
content_tag :div,
|
73
|
-
class: class_names("absolute block inset-auto top-0 right-0 mt-2 mr-2 text-sm font-semibold bg-#{badge_color}-50 border border-#{badge_color}-300 text-#{badge_color}-700 rounded shadow-lg px-2 py-px z-10", html(:badge, :classes)),
|
73
|
+
class: class_names("absolute block inset-auto top-0 right-0 mt-2 mr-2 text-sm font-semibold bg-#{badge_color}-50 border border-#{badge_color}-300 text-#{badge_color}-700 rounded-sm shadow-lg px-2 py-px z-10", html(:badge, :classes)),
|
74
74
|
title: @card[:badge_title],
|
75
75
|
style: html(:badge, :style),
|
76
76
|
data: {target: :badge, tippy: :tooltip, **(html(:badge, :data).presence || {})} do
|
@@ -16,7 +16,7 @@
|
|
16
16
|
<% end %>
|
17
17
|
</turbo-frame>
|
18
18
|
<% else %>
|
19
|
-
<div class="bg-white rounded shadow-panel"
|
19
|
+
<div class="bg-white rounded-sm shadow-panel"
|
20
20
|
data-component-name="<%= self.class.to_s.underscore %>">
|
21
21
|
<%= helpers.empty_state by_association: params[:related_name].present?, view_type: :grid %>
|
22
22
|
</div>
|
@@ -39,7 +39,7 @@
|
|
39
39
|
<% end %>
|
40
40
|
<table class="w-full px-4 bg-white">
|
41
41
|
<%= render partial: 'avo/partials/table_header', locals: {fields: @header_fields} %>
|
42
|
-
<%= content_tag :tbody, class: "divide-y",
|
42
|
+
<%= content_tag :tbody, class: "divide-y divide-gray-200",
|
43
43
|
data: {
|
44
44
|
**(try(:drag_reorder_data_attributes) || {}),
|
45
45
|
} do %>
|
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
<%= content_tag :tr,
|
4
4
|
id: "#{self.class.to_s.underscore}_#{@resource.record.to_param}",
|
5
|
-
class: class_names("group bg-white hover:bg-gray-50 z-21 border-b", {"cursor-pointer": click_row_to_view_record}),
|
5
|
+
class: class_names("group bg-white hover:bg-gray-50 z-21 border-b border-gray-200", {"cursor-pointer": click_row_to_view_record}),
|
6
6
|
data: {
|
7
7
|
index: @index,
|
8
8
|
component_name: self.class.to_s.underscore,
|
@@ -24,7 +24,7 @@
|
|
24
24
|
<% end %>
|
25
25
|
<% if @resource.render_row_controls_on_the_left? %>
|
26
26
|
<td class="<%= @resource.row_controls_classes %>" data-control="resource-controls">
|
27
|
-
<div class="flex items-center justify-end
|
27
|
+
<div class="flex items-center justify-end grow-0 h-full">
|
28
28
|
<%= render resource_controls_component %>
|
29
29
|
</div>
|
30
30
|
</td>
|
@@ -46,7 +46,7 @@
|
|
46
46
|
<% end %>
|
47
47
|
<% if @resource.render_row_controls_on_the_right? %>
|
48
48
|
<td class="<%= @resource.row_controls_classes %>" data-control="resource-controls">
|
49
|
-
<div class="flex items-center justify-end
|
49
|
+
<div class="flex items-center justify-end grow-0 h-full">
|
50
50
|
<%= render resource_controls_component %>
|
51
51
|
</div>
|
52
52
|
</td>
|
@@ -7,7 +7,7 @@
|
|
7
7
|
<% end %>
|
8
8
|
<% end %>
|
9
9
|
<% c.with_body do %>
|
10
|
-
<% content_tag :div, class: "divide-y overflow-auto" do %>
|
10
|
+
<% content_tag :div, class: "divide-y divide-gray-200 overflow-auto" do %>
|
11
11
|
<%= render Avo::Items::VisibleItemsComponent.new resource: @resource, item: @item, view: @view, form: @form %>
|
12
12
|
<% end %>
|
13
13
|
<% end %>
|
@@ -24,7 +24,7 @@
|
|
24
24
|
<%= link_to "Delete", helpers.avo.media_library_path(@blob), class: "text-red-500", data: {turbo_confirm: "Are you sure you want to destroy this attachment?", turbo_method: :delete} %>
|
25
25
|
</div>
|
26
26
|
</div>
|
27
|
-
<div class="flex flex-col w-1/2 @3xl/details:w-1/3 border-l">
|
27
|
+
<div class="flex flex-col w-1/2 @3xl/details:w-1/3 border-l border-gray-200">
|
28
28
|
<%= render partial: "avo/media_library/information", locals: {blob: @blob} %>
|
29
29
|
<%= render partial: "avo/media_library/form", locals: {blob: @blob} %>
|
30
30
|
</div>
|
@@ -3,7 +3,7 @@
|
|
3
3
|
data-modal-target="modal"
|
4
4
|
data-modal-close-modal-on-backdrop-click-value="<%= close_modal_on_backdrop_click %>"
|
5
5
|
>
|
6
|
-
<div aria-expanded="true" class="modal-overlay absolute w-full h-full bg-
|
6
|
+
<div aria-expanded="true" class="modal-overlay absolute w-full h-full bg-gray-800/25 flex justify-center items-center" data-modal-target="backdrop" data-action="click->modal#close"></div>
|
7
7
|
<div aria-expanded="true" role="dialog" aria-modal="true" class="modal-body rounded-lg inset-auto bg-white flex z-50 relative shadow-modal <%= overflow_classes %> <%= width_classes %> <%= height_classes %>">
|
8
8
|
<div class="flex-1 flex flex-col justify-between">
|
9
9
|
<div>
|
@@ -7,7 +7,7 @@
|
|
7
7
|
<%= content_tag :label, name: t('avo.per_page').downcase do %>
|
8
8
|
<%= select_tag 'per_page',
|
9
9
|
options_for_select(per_page_options, @index_params[:per_page]),
|
10
|
-
class: 'appearance-none inline-flex bg-white-100 disabled:bg-white-400 disabled:cursor-not-allowed focus:bg-white text-slate-700 disabled:text-slate-600 rounded-md py-1 px-2 leading-tight border border-slate-300 outline-
|
10
|
+
class: 'appearance-none inline-flex bg-white-100 disabled:bg-white-400 disabled:cursor-not-allowed focus:bg-white text-slate-700 disabled:text-slate-600 rounded-md py-1 px-2 leading-tight border border-slate-300 outline-hidden focus:border-slate-400 w-16 mr-1 text-sm',
|
11
11
|
data: {
|
12
12
|
'turbo-frame': @turbo_frame,
|
13
13
|
'per-page-target': 'selector',
|
@@ -30,7 +30,6 @@
|
|
30
30
|
<% end %>
|
31
31
|
|
32
32
|
<% if @pagy.pages > 1 %>
|
33
|
-
<%# @todo: add first & last page. make the first and last buttons rounded %>
|
34
33
|
<%== helpers.pagy_nav @pagy, anchor_string: "data-turbo-frame=\"#{@turbo_frame}\"" %>
|
35
34
|
<% end %>
|
36
35
|
</div>
|
@@ -27,12 +27,12 @@
|
|
27
27
|
</div>
|
28
28
|
</div>
|
29
29
|
<% if sidebar? %>
|
30
|
-
<div class="max-w-full sm:w-1/3
|
30
|
+
<div class="max-w-full sm:w-1/3 shrink-0 h-full">
|
31
31
|
<%= sidebar %>
|
32
32
|
</div>
|
33
33
|
<% end %>
|
34
34
|
<% if bare_sidebar? %>
|
35
|
-
<div class="max-w-full sm:w-1/3
|
35
|
+
<div class="max-w-full sm:w-1/3 shrink-0 h-full">
|
36
36
|
<%= bare_sidebar %>
|
37
37
|
</div>
|
38
38
|
<% end %>
|