avo 4.0.0.beta.2 → 4.0.0.beta.3
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/Gemfile.lock +1 -1
- data/app/assets/builds/avo/application.css +247 -28
- data/app/assets/stylesheets/application.css +1 -0
- data/app/assets/stylesheets/css/components/ui/state.css +129 -0
- data/app/assets/stylesheets/css/pagination.css +12 -6
- data/app/assets/svgs/avo/circle-minus.svg +3 -0
- data/app/components/avo/alert_component.rb +4 -4
- data/app/components/avo/backtrace_alert_component.html.erb +1 -1
- data/app/components/avo/button_component.rb +1 -1
- data/app/components/avo/debug/status_component.html.erb +2 -2
- data/app/components/avo/empty_state_component.html.erb +15 -4
- data/app/components/avo/empty_state_component.rb +9 -0
- data/app/components/avo/fields/common/files/view_type/grid_item_component.html.erb +1 -1
- data/app/components/avo/fields/common/key_value_component.html.erb +1 -1
- data/app/components/avo/fields/common/stars_component.html.erb +1 -1
- data/app/components/avo/fields/common/status_viewer_component.html.erb +3 -3
- data/app/components/avo/fields/preview_field/index_component.rb +1 -1
- data/app/components/avo/fields/stars_field/edit_component.html.erb +1 -1
- data/app/components/avo/filters_component.html.erb +1 -1
- data/app/components/avo/items/switcher_component.html.erb +1 -1
- data/app/components/avo/media_library/item_details_component.html.erb +2 -2
- data/app/components/avo/media_library/list_component.html.erb +1 -1
- data/app/components/avo/media_library/list_item_component.html.erb +2 -2
- data/app/components/avo/modal_component.html.erb +1 -1
- data/app/components/avo/paginator_component.html.erb +23 -17
- data/app/components/avo/paginator_component.rb +18 -0
- data/app/components/avo/resource_component.rb +2 -2
- data/app/components/avo/sidebar/group_component.html.erb +1 -1
- data/app/components/avo/sidebar/section_component.html.erb +1 -1
- data/app/components/avo/sidebar_profile_component.html.erb +1 -1
- data/app/components/avo/views/resource_index_component.rb +1 -1
- data/app/views/avo/base/_date_time_filter.html.erb +1 -1
- data/app/views/avo/base/preview.html.erb +1 -1
- data/app/views/avo/debug/_valid_indicator.html.erb +2 -2
- data/app/views/avo/home/failed_to_load.html.erb +40 -13
- data/app/views/avo/media_library/_form.html.erb +1 -1
- data/app/views/avo/partials/_color_scheme_switcher.html.erb +4 -4
- data/app/views/avo/partials/_custom_tools_alert.html.erb +3 -3
- data/app/views/avo/partials/_sortable_component.html.erb +3 -3
- data/app/views/avo/partials/_table_header.html.erb +1 -1
- data/app/views/avo/private/_links_and_buttons.html.erb +2 -2
- data/app/views/avo/private/design.html.erb +4 -4
- data/app/views/avo/sidebar/_license_warning.html.erb +2 -2
- data/lib/avo/version.rb +1 -1
- data/lib/generators/avo/resource_generator.rb +3 -3
- data/lib/generators/avo/templates/initializer/avo.tt +4 -4
- data/lib/generators/avo/templates/resource_tools/partial.tt +1 -1
- metadata +3 -15
- data/app/assets/svgs/avo/arrow-circle-right.svg +0 -1
- data/app/assets/svgs/avo/bell.svg +0 -3
- data/app/assets/svgs/avo/color-swatch.svg +0 -1
- data/app/assets/svgs/avo/dashboards.svg +0 -6
- data/app/assets/svgs/avo/exclamation.svg +0 -1
- data/app/assets/svgs/avo/filter.svg +0 -1
- data/app/assets/svgs/avo/logout.svg +0 -3
- data/app/assets/svgs/avo/resources.svg +0 -13
- data/app/assets/svgs/avo/save.svg +0 -8
- data/app/assets/svgs/avo/selector.svg +0 -1
- data/app/assets/svgs/avo/sort-ascending.svg +0 -1
- data/app/assets/svgs/avo/sort-descending.svg +0 -1
- data/app/assets/svgs/avo/times.svg +0 -3
- data/app/assets/svgs/avo/tools.svg +0 -3
|
@@ -3,11 +3,20 @@
|
|
|
3
3
|
class Avo::EmptyStateComponent < Avo::BaseComponent
|
|
4
4
|
prop :message
|
|
5
5
|
prop :by_association, default: false
|
|
6
|
+
prop :classes
|
|
6
7
|
|
|
7
8
|
def text
|
|
8
9
|
@message || locale_message
|
|
9
10
|
end
|
|
10
11
|
|
|
12
|
+
def cards
|
|
13
|
+
[
|
|
14
|
+
{number: 1, position: :top, title: :large},
|
|
15
|
+
{number: 2, position: :middle, title: :large},
|
|
16
|
+
{number: 3, position: :bottom, title: :large}
|
|
17
|
+
]
|
|
18
|
+
end
|
|
19
|
+
|
|
11
20
|
private
|
|
12
21
|
|
|
13
22
|
def locale_message
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
<% else %>
|
|
10
10
|
<%= content_tag file.representable? ? :a : :div, **document_arguments do %>
|
|
11
11
|
<div class="flex flex-col justify-center items-center w-full">
|
|
12
|
-
<%= helpers.svg "
|
|
12
|
+
<%= helpers.svg "tabler/outline/file-text", class: 'h-10 text-gray-600 mb-2' %>
|
|
13
13
|
</div>
|
|
14
14
|
<% end %>
|
|
15
15
|
<% end %>
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
data-action="click->key-value#addRow"
|
|
23
23
|
class="key-value__action-button <%= 'cursor-not-allowed' if @field.disable_adding_rows %>"
|
|
24
24
|
>
|
|
25
|
-
<%= helpers.svg "
|
|
25
|
+
<%= helpers.svg "tabler/outline/circle-plus", class: 'key-value__action-icon' %>
|
|
26
26
|
</a>
|
|
27
27
|
</div>
|
|
28
28
|
<% end %>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<div class="rating-group" data-component="<%= component_name %>">
|
|
2
2
|
<% (1..@max).each do |rating_value| %>
|
|
3
3
|
<%= helpers.svg(
|
|
4
|
-
'
|
|
4
|
+
'tabler/filled/star',
|
|
5
5
|
class: class_names("star inline-block me-0.5", filled: rating_value <= (@value || 0))
|
|
6
6
|
) %>
|
|
7
7
|
<% end %>
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
<div class=" <%= class_names("flex shrink-0 items-center", "text-red-600": @status == 'failed', "text-green-600": @status == 'success', "text-gray-600": @status == 'neutral') %>">
|
|
2
2
|
<% if @status == 'success' %>
|
|
3
|
-
<%= helpers.svg '
|
|
3
|
+
<%= helpers.svg 'tabler/filled/circle-check', class: 'h-4' %>
|
|
4
4
|
<% elsif @status == 'failed' %>
|
|
5
|
-
<%= helpers.svg '
|
|
5
|
+
<%= helpers.svg 'tabler/filled/circle-x', class: 'h-4' %>
|
|
6
6
|
<% elsif @status == 'neutral' %>
|
|
7
|
-
<%= helpers.svg '
|
|
7
|
+
<%= helpers.svg 'avo/circle-minus', class: 'h-4' %>
|
|
8
8
|
<% elsif @status == 'loading' %>
|
|
9
9
|
<div class="spinner">
|
|
10
10
|
<div class="double-bounce1"></div>
|
|
@@ -4,7 +4,7 @@ class Avo::Fields::PreviewField::IndexComponent < Avo::Fields::IndexComponent
|
|
|
4
4
|
def render_preview
|
|
5
5
|
link_to resource_view_path, title: t("avo.view_item", item: @resource.name).humanize do
|
|
6
6
|
helpers.svg(
|
|
7
|
-
"
|
|
7
|
+
"tabler/outline/zoom-scan",
|
|
8
8
|
class: "block h-6 text-gray-600",
|
|
9
9
|
data: {
|
|
10
10
|
controller: "preview",
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
data-max="<%= @field.max %>"
|
|
10
10
|
data-current-value="<%= @field.value || 0 %>">
|
|
11
11
|
<% (1..@field.max).each do |rating_value| %>
|
|
12
|
-
<%= helpers.svg('
|
|
12
|
+
<%= helpers.svg('tabler/filled/star',
|
|
13
13
|
class: class_names("star inline-block me-0.5", filled: rating_value <= (@value || 0)),
|
|
14
14
|
data: {
|
|
15
15
|
star_value: rating_value,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<div class="relative w-full flex justify-between">
|
|
3
3
|
<%= a_button class: 'focus:outline-hidden',
|
|
4
4
|
style: :primary,
|
|
5
|
-
icon: "
|
|
5
|
+
icon: "tabler/outline/filter",
|
|
6
6
|
title: t('avo.click_to_reveal_filters'),
|
|
7
7
|
'data-button': 'resource-filters',
|
|
8
8
|
'data-action': 'click->toggle#togglePanel',
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
<% end %>
|
|
28
28
|
<% end %>
|
|
29
29
|
<% elsif item.is_collaboration? %>
|
|
30
|
-
<%= render Avo::
|
|
30
|
+
<%= render Avo::Collaboration::TimelineComponent.new(resource: @resource) %>
|
|
31
31
|
<% elsif item.is_header? %>
|
|
32
32
|
<% if @resource.cover.present? && @resource.cover.visible_in_current_view? %>
|
|
33
33
|
<%= render Avo::CoverComponent.new cover: @resource.cover %>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<div class="relative flex flex-col w-full max @container/details">
|
|
2
|
-
<%= link_to helpers.svg('
|
|
2
|
+
<%= link_to helpers.svg('tabler/outline/x', class: "size-6"), helpers.avo.media_library_index_path,
|
|
3
3
|
class: "absolute z-10 inset-auto end-0 top-0 mt-2 me-2 block bg-white p-1 rounded-lg text-slate-600 hover:text-slate-900",
|
|
4
4
|
title: t('avo.close'),
|
|
5
5
|
data: {
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
<%= video_tag(helpers.main_app.url_for(@blob), controls: true, preload: false, class: 'w-full') %>
|
|
16
16
|
<% else %>
|
|
17
17
|
<div class="relative h-full flex flex-col justify-center items-center w-full bg-slate-100">
|
|
18
|
-
<%= helpers.svg "
|
|
18
|
+
<%= helpers.svg "tabler/outline/file-text", class: 'h-10 text-gray-600 mb-2' %>
|
|
19
19
|
</div>
|
|
20
20
|
<% end %>
|
|
21
21
|
<div class="flex justify-center w-full text-sm gap-4">
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
media_library_attach_target: 'dropzone',
|
|
29
29
|
action: 'click->media-library-attach#triggerFileBrowser',
|
|
30
30
|
} do %>
|
|
31
|
-
<%= helpers.svg '
|
|
31
|
+
<%= helpers.svg 'tabler/outline/cloud-upload', class: 'size-6 text-gray-400' %> Upload a file
|
|
32
32
|
<small>Click to browse or drag and drop</small>
|
|
33
33
|
<% end %>
|
|
34
34
|
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
class: "relative group min-h-full max-w-full flex-1 flex flex-col justify-between gap-2 border border-slate-200 p-1.5 rounded-xl hover:border-blue-500 hover:outline data-[selected=true]:border-blue-500 data-[selected=true]:outline outline-blue-500",
|
|
4
4
|
data: do %>
|
|
5
5
|
<% if false && @attaching %>
|
|
6
|
-
<div class="absolute bg-blue-500 group-hover:opacity-100 group-data-[selected=true]:opacity-100 opacity-0 inset-auto start-0 top-0 text-white rounded-ss-xl rounded-ee-xl -ms-px -mt-px p-2"><div class="border border-white"><%= helpers.svg "
|
|
6
|
+
<div class="absolute bg-blue-500 group-hover:opacity-100 group-data-[selected=true]:opacity-100 opacity-0 inset-auto start-0 top-0 text-white rounded-ss-xl rounded-ee-xl -ms-px -mt-px p-2"><div class="border border-white"><%= helpers.svg "tabler/outline/check", class: 'group-data-[selected=true]:opacity-100 opacity-0 size-4' %></div></div>
|
|
7
7
|
<% end %>
|
|
8
8
|
<div class="flex flex-col h-full aspect-video overflow-hidden rounded-lg justify-center items-center">
|
|
9
9
|
<% if blob.image? %>
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
<%= video_tag(helpers.main_app.url_for(blob), controls: true, preload: false, class: 'w-full') %>
|
|
15
15
|
<% else %>
|
|
16
16
|
<div class="relative h-full flex flex-col justify-center items-center w-full bg-slate-100">
|
|
17
|
-
<%= helpers.svg "
|
|
17
|
+
<%= helpers.svg "tabler/outline/file-text", class: 'h-10 text-gray-600 mb-2' %>
|
|
18
18
|
</div>
|
|
19
19
|
<% end %>
|
|
20
20
|
</div>
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
<% end %>
|
|
35
35
|
<% if @show_close_button %>
|
|
36
36
|
<button class="modal__close-button" data-action="click->modal#closeModal" aria-label="<%= t('avo.close') %>">
|
|
37
|
-
<%= helpers.svg "
|
|
37
|
+
<%= helpers.svg "tabler/outline/x", class: "size-5" %>
|
|
38
38
|
</button>
|
|
39
39
|
<% end %>
|
|
40
40
|
</div>
|
|
@@ -29,23 +29,29 @@
|
|
|
29
29
|
</div>
|
|
30
30
|
|
|
31
31
|
<%# Right: info + navigation grouped pill %>
|
|
32
|
-
<div class="pagination__controls">
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
<
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
32
|
+
<div class="pagination__controls-wrap">
|
|
33
|
+
<div class="pagination__controls">
|
|
34
|
+
<% if @resource.pagination_type.default? %>
|
|
35
|
+
<div class="pagination__info">
|
|
36
|
+
<span class="pagination__info-number">
|
|
37
|
+
<%= "#{formatted_number(@pagy.from)}-#{formatted_number(@pagy.to)}" %>
|
|
38
|
+
</span>
|
|
39
|
+
of
|
|
40
|
+
<% if @pagy.count >= 10_000 %>
|
|
41
|
+
<span title="<%= formatted_count %>" data-tippy="tooltip">
|
|
42
|
+
<%= number_to_social(@pagy.count, start_at: 10_000) %>
|
|
43
|
+
</span>
|
|
44
|
+
<% else %>
|
|
45
|
+
<span><%= formatted_count %></span>
|
|
46
|
+
<% end %>
|
|
47
|
+
</div>
|
|
48
|
+
<% end %>
|
|
44
49
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
+
<% if @pagy.pages > 1 %>
|
|
51
|
+
<div class="pagination__nav">
|
|
52
|
+
<%== formatted_series_nav %>
|
|
53
|
+
</div>
|
|
54
|
+
<% end %>
|
|
55
|
+
</div>
|
|
50
56
|
</div>
|
|
51
57
|
</div>
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
class Avo::PaginatorComponent < Avo::BaseComponent
|
|
4
|
+
NUMBER_DELIMITER = "."
|
|
5
|
+
|
|
4
6
|
prop :resource
|
|
5
7
|
prop :parent_record
|
|
6
8
|
prop :parent_resource
|
|
@@ -52,4 +54,20 @@ class Avo::PaginatorComponent < Avo::BaseComponent
|
|
|
52
54
|
num = helpers.content_tag(:span, option, class: "pagination__per-page-option-num")
|
|
53
55
|
"#{num} #{t("avo.per_page").downcase}".html_safe
|
|
54
56
|
end
|
|
57
|
+
|
|
58
|
+
def formatted_count
|
|
59
|
+
formatted_number(@pagy.count)
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
def formatted_series_nav
|
|
63
|
+
@pagy.series_nav(anchor_string: %(data-turbo-frame="#{@turbo_frame}"))
|
|
64
|
+
.gsub(/>(\d{4,})</) { |match| match.sub($1, formatted_number($1)) }
|
|
65
|
+
.html_safe
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
private
|
|
69
|
+
|
|
70
|
+
def formatted_number(number)
|
|
71
|
+
helpers.number_with_delimiter(number, delimiter: NUMBER_DELIMITER)
|
|
72
|
+
end
|
|
55
73
|
end
|
|
@@ -117,7 +117,7 @@ class Avo::ResourceComponent < Avo::BaseComponent
|
|
|
117
117
|
tippy: control.title ? :tooltip : nil,
|
|
118
118
|
action: via_belongs_to ? "click->modal#close" : nil
|
|
119
119
|
}.compact,
|
|
120
|
-
icon: "
|
|
120
|
+
icon: "tabler/outline/arrow-left" do
|
|
121
121
|
control.label
|
|
122
122
|
end
|
|
123
123
|
end
|
|
@@ -181,7 +181,7 @@ class Avo::ResourceComponent < Avo::BaseComponent
|
|
|
181
181
|
style: :primary,
|
|
182
182
|
loading: true,
|
|
183
183
|
type: :submit,
|
|
184
|
-
icon: "
|
|
184
|
+
icon: "tabler/outline/device-floppy",
|
|
185
185
|
data: data_attributes do
|
|
186
186
|
control.label
|
|
187
187
|
end
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
<span class="sidebar-icon <%= 'sidebar-icon--collapsed' if collapsed %>"
|
|
15
15
|
data-menu-target="svg"
|
|
16
16
|
>
|
|
17
|
-
<%= helpers.svg '
|
|
17
|
+
<%= helpers.svg 'tabler/outline/chevron-down', class: 'h-4' %>
|
|
18
18
|
</span>
|
|
19
19
|
</button>
|
|
20
20
|
<% else %>
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
<span class="sidebar-section__icon sidebar-icon <%= 'sidebar-icon--collapsed' if collapsed %>"
|
|
16
16
|
data-menu-target="svg"
|
|
17
17
|
>
|
|
18
|
-
<%= helpers.svg '
|
|
18
|
+
<%= helpers.svg 'tabler/outline/chevron-down' %>
|
|
19
19
|
</span>
|
|
20
20
|
</button>
|
|
21
21
|
<% else %>
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
},
|
|
42
42
|
class: 'sidebar-profile__form' do |form| %>
|
|
43
43
|
<%= form.button turbo_confirm: t('avo.are_you_sure'), class: "sidebar-profile__sign-out" do %>
|
|
44
|
-
<%= helpers.svg "
|
|
44
|
+
<%= helpers.svg "tabler/outline/logout", class: 'sidebar-profile__sign-out-icon sidebar-icon' %> <%= t('avo.sign_out') %>
|
|
45
45
|
<% end %>
|
|
46
46
|
<% end %>
|
|
47
47
|
<% end %>
|
|
@@ -136,7 +136,7 @@ class Avo::Views::ResourceIndexComponent < Avo::ResourceComponent
|
|
|
136
136
|
|
|
137
137
|
a_button size: :sm,
|
|
138
138
|
color: :primary,
|
|
139
|
-
icon: "
|
|
139
|
+
icon: "tabler/outline/filter",
|
|
140
140
|
data: {
|
|
141
141
|
controller: "avo-filters",
|
|
142
142
|
action: "click->avo-filters#toggleFiltersArea",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
<div class="shadow-lg rounded px-4 py-3 relative border text-white pointer-events-auto bg-blue-400 border-blue-600 m-2">
|
|
28
28
|
<div class="flex px-2">
|
|
29
29
|
<div class="shrink-0">
|
|
30
|
-
<%= svg "
|
|
30
|
+
<%= svg "tabler/filled/alert-circle", class: "h-6" %>
|
|
31
31
|
</div>
|
|
32
32
|
<div class="ms-3 flex-1 pt-0.5">
|
|
33
33
|
<p class="text-sm leading-5 font-semibold"><%= t "avo.not_authorized" %></p>
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
<% if valid %>
|
|
2
2
|
<span class="text-green-700 text-xl">
|
|
3
|
-
<%= svg "
|
|
3
|
+
<%= svg "tabler/outline/rosette-discount-check", class: "h-5 inline -mt-1 relative" %> <span>Valid</span>
|
|
4
4
|
</span>
|
|
5
5
|
<% else %>
|
|
6
6
|
<span class="text-orange-700 text-xl">
|
|
7
|
-
<%= svg "
|
|
7
|
+
<%= svg "tabler/outline/exclamation-circle", class: "h-5 inline -mt-1 relative" %> <span>Invalid</span>
|
|
8
8
|
</span>
|
|
9
9
|
<% end %>
|
|
@@ -1,18 +1,45 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
<%
|
|
2
|
+
src_url = params[:src].present? && !params[:src].starts_with?("http://") ? CGI.escapeHTML(params[:src]) : nil
|
|
3
|
+
frame_label = if params[:turbo_frame].present?
|
|
4
|
+
params[:turbo_frame].to_s.humanize.downcase
|
|
5
|
+
else
|
|
6
|
+
"this frame"
|
|
7
|
+
end
|
|
6
8
|
%>
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
9
|
+
|
|
10
|
+
<%= render Avo::TurboFrameWrapperComponent.new(params[:turbo_frame]) do %>
|
|
11
|
+
<div class="state state--frame-load-failed">
|
|
12
|
+
<div class="state__illustration" aria-hidden="true">
|
|
13
|
+
<% %i[start center end].each do |position| %>
|
|
14
|
+
<div class="state__document state__document--<%= position %>">
|
|
15
|
+
<div class="state__document-body">
|
|
16
|
+
<div class="state__document-lines">
|
|
17
|
+
<span class="state__document-line"></span>
|
|
18
|
+
<span class="state__document-line"></span>
|
|
19
|
+
<span class="state__document-line"></span>
|
|
20
|
+
<span class="state__document-line"></span>
|
|
21
|
+
<span class="state__document-line state__document-line--short"></span>
|
|
22
|
+
</div>
|
|
23
|
+
</div>
|
|
24
|
+
</div>
|
|
25
|
+
<% end %>
|
|
26
|
+
|
|
27
|
+
<div class="state__magnifier">
|
|
28
|
+
<%= svg "tabler/outline/zoom", class: "state__magnifier-icon" %>
|
|
15
29
|
</div>
|
|
30
|
+
</div>
|
|
31
|
+
|
|
32
|
+
<p class="state__message text-center font-normal">
|
|
33
|
+
Failed to load:
|
|
34
|
+
<span class="font-bold"><%= frame_label %></span>
|
|
35
|
+
</p>
|
|
36
|
+
|
|
37
|
+
<% if Rails.env.development? && src_url.present? %>
|
|
38
|
+
<p class="state__note text-center font-normal">
|
|
39
|
+
Follow
|
|
40
|
+
<%= link_to "this link", src_url, target: "_blank", rel: "noopener", class: "state__link font-normal" %>
|
|
41
|
+
for more details about the issue and how to fix it.
|
|
42
|
+
</p>
|
|
16
43
|
<% end %>
|
|
17
44
|
</div>
|
|
18
45
|
<% end %>
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
data-action="click->toggle#togglePanel"
|
|
38
38
|
class="color-scheme-switcher__button color-scheme-switcher__button--accent"
|
|
39
39
|
title="Accent color">
|
|
40
|
-
<%= svg "
|
|
40
|
+
<%= svg "tabler/outline/color-swatch", class: "color-scheme-switcher__icon" %>
|
|
41
41
|
<span class="color-scheme-switcher__accent-badge">
|
|
42
42
|
<span class="color-scheme-switcher__accent-badge-preview color-scheme-switcher__accent-badge-preview--neutral"></span>
|
|
43
43
|
<% accent_colors.each do |accent| %>
|
|
@@ -82,7 +82,7 @@
|
|
|
82
82
|
data-scheme="auto"
|
|
83
83
|
class="color-scheme-switcher__button"
|
|
84
84
|
title="Auto (system preference)">
|
|
85
|
-
<%= svg "
|
|
85
|
+
<%= svg "tabler/outline/device-desktop", class: "color-scheme-switcher__icon" %>
|
|
86
86
|
<span class="sr-only">Auto</span>
|
|
87
87
|
</button>
|
|
88
88
|
<button type="button"
|
|
@@ -91,7 +91,7 @@
|
|
|
91
91
|
data-scheme="light"
|
|
92
92
|
class="color-scheme-switcher__button"
|
|
93
93
|
title="Light mode">
|
|
94
|
-
<%= svg "
|
|
94
|
+
<%= svg "tabler/outline/sun", class: "color-scheme-switcher__icon" %>
|
|
95
95
|
<span class="sr-only">Light</span>
|
|
96
96
|
</button>
|
|
97
97
|
<button type="button"
|
|
@@ -100,7 +100,7 @@
|
|
|
100
100
|
data-scheme="dark"
|
|
101
101
|
class="color-scheme-switcher__button"
|
|
102
102
|
title="Dark mode">
|
|
103
|
-
<%= svg "
|
|
103
|
+
<%= svg "tabler/outline/moon", class: "color-scheme-switcher__icon" %>
|
|
104
104
|
<span class="sr-only">Dark</span>
|
|
105
105
|
</button>
|
|
106
106
|
</div>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<% if @custom_tools_alert_visible %>
|
|
2
2
|
<div class="w-full inset-auto bottom-0 z-50 mb-4 opacity-75 hover:opacity-100 transition-opacity duration-150">
|
|
3
3
|
<a href="https://avohq.io/pricing" target="_blank" class="rounded-sm bg-orange-700 text-white py-2 px-4 text-sm block items-center flex leading-tight">
|
|
4
|
-
<%= svg "
|
|
4
|
+
<%= svg "tabler/outline/alert-triangle", class: "h-6 inline me-2 text-bold shrink-0 me-1" %> Warning. <%= @custom_tools_alert_visible %> This page will not be visible in a production environment.
|
|
5
5
|
</a>
|
|
6
6
|
</div>
|
|
7
7
|
<% end %>
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
%>
|
|
14
14
|
<div class="w-full inset-auto bottom-0 z-50 mb-4 opacity-75 hover:opacity-100 transition-opacity duration-150">
|
|
15
15
|
<a href="<%= url %>" target="<%= target %>" class="rounded-sm bg-orange-700 text-white py-2 px-4 text-sm items-center flex leading-tight space-x-2 rtl:space-x-reverse">
|
|
16
|
-
<%= svg "
|
|
16
|
+
<%= svg "tabler/outline/alert-triangle", class: "h-6 inline me-2 text-bold shrink-0 me-1" %>
|
|
17
17
|
<div>
|
|
18
18
|
<%= simple_format message %>
|
|
19
19
|
</div>
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
<% elsif error.is_a? String %>
|
|
23
23
|
<div class="w-full inset-auto bottom-0 z-50 mb-4 opacity-75 hover:opacity-100 transition-opacity duration-150">
|
|
24
24
|
<div class="rounded-sm bg-orange-700 text-white py-2 px-4 text-sm items-center flex leading-tight space-x-2 rtl:space-x-reverse">
|
|
25
|
-
<%= svg "
|
|
25
|
+
<%= svg "tabler/outline/alert-triangle", class: "h-6 inline me-2 text-bold shrink-0 me-1" %>
|
|
26
26
|
<div><%= simple_format error %></div>
|
|
27
27
|
</div>
|
|
28
28
|
</div>
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
<%
|
|
2
|
-
icon = "
|
|
2
|
+
icon = "tabler/outline/selector"
|
|
3
3
|
|
|
4
4
|
if params[:sort_by] == field.id.to_s
|
|
5
5
|
case params[:sort_direction]
|
|
6
6
|
when 'asc'
|
|
7
|
-
icon = "
|
|
7
|
+
icon = "tabler/outline/sort-ascending"
|
|
8
8
|
when 'desc'
|
|
9
|
-
icon = "
|
|
9
|
+
icon = "tabler/outline/sort-descending"
|
|
10
10
|
end
|
|
11
11
|
end
|
|
12
12
|
%>
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
class="cursor-pointer <%= text_classes %>"
|
|
88
88
|
data-action="click->toggle#togglePanel"
|
|
89
89
|
>
|
|
90
|
-
<%= svg '
|
|
90
|
+
<%= svg 'tabler/filled/chart-pie-4', class: 'h-3 ms-1' %>
|
|
91
91
|
</div>
|
|
92
92
|
<turbo-frame
|
|
93
93
|
id="summary-frame-<%= field.id %>"
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
%>
|
|
29
29
|
<%
|
|
30
30
|
a_button_or_link = "a_#{entity}"
|
|
31
|
-
args = {icon: "
|
|
31
|
+
args = {icon: "tabler/outline/arrow-left", style: style, color: color, size: size, class: extra_classes, disabled: state == :disabled}
|
|
32
32
|
%>
|
|
33
33
|
<% if entity == :link %>
|
|
34
34
|
<div>
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
<% end %>
|
|
44
44
|
</div>
|
|
45
45
|
<div>
|
|
46
|
-
<%= a_button icon: "
|
|
46
|
+
<%= a_button icon: "tabler/outline/bell", style: style, color: color, size: size, class: extra_classes, disabled: state == :disabled %>
|
|
47
47
|
</div>
|
|
48
48
|
<% end %>
|
|
49
49
|
<% end %>
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
<div class="flex flex-col">
|
|
2
2
|
<%= render ui.panel(title: 'Welcome to Avo', description: 'This page is visible only in development. It will be hidden in other environments.') do |panel| %>
|
|
3
3
|
<% panel.with_controls do %>
|
|
4
|
-
<%= a_link('/admin', icon: "
|
|
4
|
+
<%= a_link('/admin', icon: "tabler/outline/arrow-left", color: :green, style: :primary, is_link: true) do %>
|
|
5
5
|
Primary
|
|
6
6
|
<% end %>
|
|
7
7
|
|
|
8
|
-
<%= a_link('/admin', icon: "
|
|
8
|
+
<%= a_link('/admin', icon: "tabler/outline/arrow-left", style: :outline, is_link: true) do %>
|
|
9
9
|
Outline
|
|
10
10
|
<% end %>
|
|
11
11
|
|
|
12
|
-
<%= a_link('/admin', icon: "
|
|
12
|
+
<%= a_link('/admin', icon: "tabler/outline/arrow-left", style: :outline, color: :red, is_link: true) do %>
|
|
13
13
|
Red
|
|
14
14
|
<% end %>
|
|
15
15
|
|
|
16
|
-
<%= a_link('/admin', icon: "
|
|
16
|
+
<%= a_link('/admin', icon: "tabler/outline/arrow-left", style: :text, color: :orange, is_link: true) do %>
|
|
17
17
|
Text
|
|
18
18
|
<% end %>
|
|
19
19
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
<div class="w-10/12 ms-1/12 inset-auto bottom-0 z-50 my-4 opacity-50 hover:opacity-100 transition-opacity duration-150 group">
|
|
2
2
|
<a href="https://avohq.io/pricing" target="_blank" class="rounded-sm bg-green-700 text-white py-2 px-4 text-sm block group-hover:pt-4">
|
|
3
|
-
<%= svg "
|
|
3
|
+
<%= svg "tabler/outline/alert-triangle", class: 'h-6 inline me-1 text-bold' %> <%= title %>
|
|
4
4
|
<div class="group-hover:block hidden py-2">
|
|
5
|
-
<%= message %> <%= svg "
|
|
5
|
+
<%= message %> <%= svg "tabler/outline/circle-arrow-right", class: "h-6 inline float-right" %>
|
|
6
6
|
</div>
|
|
7
7
|
</a>
|
|
8
8
|
</div>
|
data/lib/avo/version.rb
CHANGED
|
@@ -341,8 +341,8 @@ module Generators
|
|
|
341
341
|
event: "tabler/outline/calendar-event",
|
|
342
342
|
notification: "tabler/outline/bell",
|
|
343
343
|
message: "tabler/outline/mail",
|
|
344
|
-
setting: "
|
|
345
|
-
report: "tabler/
|
|
344
|
+
setting: "heroicons/outline/cog",
|
|
345
|
+
report: "tabler/filled/chart-pie-4",
|
|
346
346
|
task: "tabler/outline/checklist",
|
|
347
347
|
review: "tabler/outline/star",
|
|
348
348
|
photo: "tabler/outline/photo",
|
|
@@ -356,7 +356,7 @@ module Generators
|
|
|
356
356
|
plan: "tabler/outline/list",
|
|
357
357
|
address: "tabler/outline/map-pin",
|
|
358
358
|
location: "tabler/outline/map-pin",
|
|
359
|
-
country: "tabler/outline/
|
|
359
|
+
country: "tabler/outline/world",
|
|
360
360
|
city: "tabler/outline/building-community",
|
|
361
361
|
account: "tabler/outline/user-circle",
|
|
362
362
|
}.freeze
|
|
@@ -141,19 +141,19 @@ Avo.configure do |config|
|
|
|
141
141
|
|
|
142
142
|
## == Menus ==
|
|
143
143
|
# config.main_menu = -> {
|
|
144
|
-
# section "Dashboards", icon: "
|
|
144
|
+
# section "Dashboards", icon: "tabler/outline/layout-dashboard" do
|
|
145
145
|
# all_dashboards
|
|
146
146
|
# end
|
|
147
147
|
|
|
148
|
-
# section "Resources", icon: "
|
|
148
|
+
# section "Resources", icon: "tabler/outline/chart-bar-popular" do
|
|
149
149
|
# all_resources
|
|
150
150
|
# end
|
|
151
151
|
|
|
152
|
-
# section "Tools", icon: "
|
|
152
|
+
# section "Tools", icon: "tabler/outline/tool" do
|
|
153
153
|
# all_tools
|
|
154
154
|
# end
|
|
155
155
|
# }
|
|
156
156
|
# config.profile_menu = -> {
|
|
157
|
-
# link "Profile", path: "/<%= options[:path] %>/profile", icon: "
|
|
157
|
+
# link "Profile", path: "/<%= options[:path] %>/profile", icon: "tabler/outline/user-circle"
|
|
158
158
|
# }
|
|
159
159
|
end
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<div class="flex flex-col">
|
|
2
2
|
<%%= render ui.panel(title: "<%= human_name %>") do |panel| %>
|
|
3
3
|
<%% panel.with_controls do %>
|
|
4
|
-
<%%= a_link('/avo', icon: '
|
|
4
|
+
<%%= a_link('/avo', icon: 'tabler/outline/school', color: :primary, style: :primary) do %>
|
|
5
5
|
Dummy link
|
|
6
6
|
<%% end %>
|
|
7
7
|
<%% end %>
|