avo 1.25.2 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of avo might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/Gemfile +10 -1
- data/Gemfile.lock +19 -6
- data/README.md +33 -28
- data/app/assets/stylesheets/avo.css +7 -2
- data/app/assets/stylesheets/css/breadcrumbs.css +6 -2
- data/app/assets/stylesheets/css/buttons.css +16 -0
- data/app/assets/stylesheets/css/fonts.css +42 -16
- data/app/assets/stylesheets/css/pagination.css +9 -9
- data/app/assets/stylesheets/css/search.css +18 -7
- data/app/assets/stylesheets/css/tooltips.css +1 -0
- data/app/assets/stylesheets/css/typography.css +4 -2
- data/app/assets/svgs/bell.svg +3 -0
- data/app/assets/svgs/dashboards-icon.svg +6 -0
- data/app/assets/svgs/detach.svg +8 -0
- data/app/assets/svgs/edit.svg +5 -1
- data/app/assets/svgs/grid-empty-state.svg +37 -0
- data/app/assets/svgs/grid-view-type.svg +5 -0
- data/app/assets/svgs/heroicons/outline/academic-cap.svg +5 -0
- data/app/assets/svgs/heroicons/outline/adjustments.svg +3 -0
- data/app/assets/svgs/heroicons/outline/annotation.svg +3 -0
- data/app/assets/svgs/heroicons/outline/archive.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-circle-down.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-circle-left.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-circle-right.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-circle-up.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-down.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-left.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-narrow-down.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-narrow-left.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-narrow-right.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-narrow-up.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-right.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-sm-down.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-sm-left.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-sm-right.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-sm-up.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrow-up.svg +3 -0
- data/app/assets/svgs/heroicons/outline/arrows-expand.svg +3 -0
- data/app/assets/svgs/heroicons/outline/at-symbol.svg +3 -0
- data/app/assets/svgs/heroicons/outline/backspace.svg +3 -0
- data/app/assets/svgs/heroicons/outline/badge-check.svg +3 -0
- data/app/assets/svgs/heroicons/outline/ban.svg +3 -0
- data/app/assets/svgs/heroicons/outline/beaker.svg +3 -0
- data/app/assets/svgs/heroicons/outline/bell.svg +3 -0
- data/app/assets/svgs/heroicons/outline/book-open.svg +3 -0
- data/app/assets/svgs/heroicons/outline/bookmark-alt.svg +3 -0
- data/app/assets/svgs/heroicons/outline/bookmark.svg +3 -0
- data/app/assets/svgs/heroicons/outline/briefcase.svg +3 -0
- data/app/assets/svgs/heroicons/outline/cake.svg +3 -0
- data/app/assets/svgs/heroicons/outline/calculator.svg +3 -0
- data/app/assets/svgs/heroicons/outline/calendar.svg +3 -0
- data/app/assets/svgs/heroicons/outline/camera.svg +4 -0
- data/app/assets/svgs/heroicons/outline/cash.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chart-bar.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chart-pie.svg +4 -0
- data/app/assets/svgs/heroicons/outline/chart-square-bar.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chat-alt-2.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chat-alt.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chat.svg +3 -0
- data/app/assets/svgs/heroicons/outline/check-circle.svg +3 -0
- data/app/assets/svgs/heroicons/outline/check.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chevron-double-down.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chevron-double-left.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chevron-double-right.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chevron-double-up.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chevron-down.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chevron-left.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chevron-right.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chevron-up.svg +3 -0
- data/app/assets/svgs/heroicons/outline/chip.svg +3 -0
- data/app/assets/svgs/heroicons/outline/clipboard-check.svg +3 -0
- data/app/assets/svgs/heroicons/outline/clipboard-copy.svg +3 -0
- data/app/assets/svgs/heroicons/outline/clipboard-list.svg +3 -0
- data/app/assets/svgs/heroicons/outline/clipboard.svg +3 -0
- data/app/assets/svgs/heroicons/outline/clock.svg +3 -0
- data/app/assets/svgs/heroicons/outline/cloud-download.svg +3 -0
- data/app/assets/svgs/heroicons/outline/cloud-upload.svg +3 -0
- data/app/assets/svgs/heroicons/outline/cloud.svg +3 -0
- data/app/assets/svgs/heroicons/outline/code.svg +3 -0
- data/app/assets/svgs/heroicons/outline/cog.svg +4 -0
- data/app/assets/svgs/heroicons/outline/collection.svg +3 -0
- data/app/assets/svgs/heroicons/outline/color-swatch.svg +3 -0
- data/app/assets/svgs/heroicons/outline/credit-card.svg +3 -0
- data/app/assets/svgs/heroicons/outline/cube-transparent.svg +3 -0
- data/app/assets/svgs/heroicons/outline/cube.svg +3 -0
- data/app/assets/svgs/heroicons/outline/currency-bangladeshi.svg +3 -0
- data/app/assets/svgs/heroicons/outline/currency-dollar.svg +3 -0
- data/app/assets/svgs/heroicons/outline/currency-euro.svg +3 -0
- data/app/assets/svgs/heroicons/outline/currency-pound.svg +3 -0
- data/app/assets/svgs/heroicons/outline/currency-rupee.svg +3 -0
- data/app/assets/svgs/heroicons/outline/currency-yen.svg +3 -0
- data/app/assets/svgs/heroicons/outline/cursor-click.svg +3 -0
- data/app/assets/svgs/heroicons/outline/database.svg +3 -0
- data/app/assets/svgs/heroicons/outline/desktop-computer.svg +3 -0
- data/app/assets/svgs/heroicons/outline/device-mobile.svg +3 -0
- data/app/assets/svgs/heroicons/outline/device-tablet.svg +3 -0
- data/app/assets/svgs/heroicons/outline/document-add.svg +3 -0
- data/app/assets/svgs/heroicons/outline/document-download.svg +3 -0
- data/app/assets/svgs/heroicons/outline/document-duplicate.svg +3 -0
- data/app/assets/svgs/heroicons/outline/document-remove.svg +3 -0
- data/app/assets/svgs/heroicons/outline/document-report.svg +3 -0
- data/app/assets/svgs/heroicons/outline/document-search.svg +3 -0
- data/app/assets/svgs/heroicons/outline/document-text.svg +3 -0
- data/app/assets/svgs/heroicons/outline/document.svg +3 -0
- data/app/assets/svgs/heroicons/outline/dots-circle-horizontal.svg +3 -0
- data/app/assets/svgs/heroicons/outline/dots-horizontal.svg +3 -0
- data/app/assets/svgs/heroicons/outline/dots-vertical.svg +3 -0
- data/app/assets/svgs/heroicons/outline/download.svg +3 -0
- data/app/assets/svgs/heroicons/outline/duplicate.svg +3 -0
- data/app/assets/svgs/heroicons/outline/emoji-happy.svg +3 -0
- data/app/assets/svgs/heroicons/outline/emoji-sad.svg +3 -0
- data/app/assets/svgs/heroicons/outline/exclamation-circle.svg +3 -0
- data/app/assets/svgs/heroicons/outline/exclamation.svg +3 -0
- data/app/assets/svgs/heroicons/outline/external-link.svg +3 -0
- data/app/assets/svgs/heroicons/outline/eye-off.svg +3 -0
- data/app/assets/svgs/heroicons/outline/eye.svg +4 -0
- data/app/assets/svgs/heroicons/outline/fast-forward.svg +3 -0
- data/app/assets/svgs/heroicons/outline/film.svg +3 -0
- data/app/assets/svgs/heroicons/outline/filter.svg +3 -0
- data/app/assets/svgs/heroicons/outline/finger-print.svg +3 -0
- data/app/assets/svgs/heroicons/outline/fire.svg +4 -0
- data/app/assets/svgs/heroicons/outline/flag.svg +3 -0
- data/app/assets/svgs/heroicons/outline/folder-add.svg +3 -0
- data/app/assets/svgs/heroicons/outline/folder-download.svg +3 -0
- data/app/assets/svgs/heroicons/outline/folder-open.svg +3 -0
- data/app/assets/svgs/heroicons/outline/folder-remove.svg +3 -0
- data/app/assets/svgs/heroicons/outline/folder.svg +3 -0
- data/app/assets/svgs/heroicons/outline/gift.svg +3 -0
- data/app/assets/svgs/heroicons/outline/globe-alt.svg +3 -0
- data/app/assets/svgs/heroicons/outline/globe.svg +3 -0
- data/app/assets/svgs/heroicons/outline/hand.svg +3 -0
- data/app/assets/svgs/heroicons/outline/hashtag.svg +3 -0
- data/app/assets/svgs/heroicons/outline/heart.svg +3 -0
- data/app/assets/svgs/heroicons/outline/home.svg +3 -0
- data/app/assets/svgs/heroicons/outline/identification.svg +3 -0
- data/app/assets/svgs/heroicons/outline/inbox-in.svg +3 -0
- data/app/assets/svgs/heroicons/outline/inbox.svg +3 -0
- data/app/assets/svgs/heroicons/outline/information-circle.svg +3 -0
- data/app/assets/svgs/heroicons/outline/key.svg +3 -0
- data/app/assets/svgs/heroicons/outline/library.svg +3 -0
- data/app/assets/svgs/heroicons/outline/light-bulb.svg +3 -0
- data/app/assets/svgs/heroicons/outline/lightning-bolt.svg +3 -0
- data/app/assets/svgs/heroicons/outline/link.svg +3 -0
- data/app/assets/svgs/heroicons/outline/location-marker.svg +4 -0
- data/app/assets/svgs/heroicons/outline/lock-closed.svg +3 -0
- data/app/assets/svgs/heroicons/outline/lock-open.svg +3 -0
- data/app/assets/svgs/heroicons/outline/login.svg +3 -0
- data/app/assets/svgs/heroicons/outline/logout.svg +3 -0
- data/app/assets/svgs/heroicons/outline/mail-open.svg +3 -0
- data/app/assets/svgs/heroicons/outline/mail.svg +3 -0
- data/app/assets/svgs/heroicons/outline/map.svg +3 -0
- data/app/assets/svgs/heroicons/outline/menu-alt-1.svg +3 -0
- data/app/assets/svgs/heroicons/outline/menu-alt-2.svg +3 -0
- data/app/assets/svgs/heroicons/outline/menu-alt-3.svg +3 -0
- data/app/assets/svgs/heroicons/outline/menu-alt-4.svg +3 -0
- data/app/assets/svgs/heroicons/outline/menu.svg +3 -0
- data/app/assets/svgs/heroicons/outline/microphone.svg +3 -0
- data/app/assets/svgs/heroicons/outline/minus-circle.svg +3 -0
- data/app/assets/svgs/heroicons/outline/minus-sm.svg +3 -0
- data/app/assets/svgs/heroicons/outline/minus.svg +3 -0
- data/app/assets/svgs/heroicons/outline/moon.svg +3 -0
- data/app/assets/svgs/heroicons/outline/music-note.svg +3 -0
- data/app/assets/svgs/heroicons/outline/newspaper.svg +3 -0
- data/app/assets/svgs/heroicons/outline/office-building.svg +3 -0
- data/app/assets/svgs/heroicons/outline/paper-airplane.svg +3 -0
- data/app/assets/svgs/heroicons/outline/paper-clip.svg +3 -0
- data/app/assets/svgs/heroicons/outline/pause.svg +3 -0
- data/app/assets/svgs/heroicons/outline/pencil-alt.svg +3 -0
- data/app/assets/svgs/heroicons/outline/pencil.svg +3 -0
- data/app/assets/svgs/heroicons/outline/phone-incoming.svg +3 -0
- data/app/assets/svgs/heroicons/outline/phone-missed-call.svg +3 -0
- data/app/assets/svgs/heroicons/outline/phone-outgoing.svg +3 -0
- data/app/assets/svgs/heroicons/outline/phone.svg +3 -0
- data/app/assets/svgs/heroicons/outline/photograph.svg +3 -0
- data/app/assets/svgs/heroicons/outline/play.svg +4 -0
- data/app/assets/svgs/heroicons/outline/plus-circle.svg +3 -0
- data/app/assets/svgs/heroicons/outline/plus-sm.svg +3 -0
- data/app/assets/svgs/heroicons/outline/plus.svg +3 -0
- data/app/assets/svgs/heroicons/outline/presentation-chart-bar.svg +3 -0
- data/app/assets/svgs/heroicons/outline/presentation-chart-line.svg +3 -0
- data/app/assets/svgs/heroicons/outline/printer.svg +3 -0
- data/app/assets/svgs/heroicons/outline/puzzle.svg +3 -0
- data/app/assets/svgs/heroicons/outline/qrcode.svg +3 -0
- data/app/assets/svgs/heroicons/outline/question-mark-circle.svg +3 -0
- data/app/assets/svgs/heroicons/outline/receipt-refund.svg +3 -0
- data/app/assets/svgs/heroicons/outline/receipt-tax.svg +3 -0
- data/app/assets/svgs/heroicons/outline/refresh.svg +3 -0
- data/app/assets/svgs/heroicons/outline/reply.svg +3 -0
- data/app/assets/svgs/heroicons/outline/rewind.svg +3 -0
- data/app/assets/svgs/heroicons/outline/rss.svg +3 -0
- data/app/assets/svgs/heroicons/outline/save-as.svg +3 -0
- data/app/assets/svgs/heroicons/outline/save.svg +3 -0
- data/app/assets/svgs/heroicons/outline/scale.svg +3 -0
- data/app/assets/svgs/heroicons/outline/scissors.svg +3 -0
- data/app/assets/svgs/heroicons/outline/search-circle.svg +3 -0
- data/app/assets/svgs/heroicons/outline/search.svg +3 -0
- data/app/assets/svgs/heroicons/outline/selector.svg +3 -0
- data/app/assets/svgs/heroicons/outline/server.svg +3 -0
- data/app/assets/svgs/heroicons/outline/share.svg +3 -0
- data/app/assets/svgs/heroicons/outline/shield-check.svg +3 -0
- data/app/assets/svgs/heroicons/outline/shield-exclamation.svg +3 -0
- data/app/assets/svgs/heroicons/outline/shopping-bag.svg +3 -0
- data/app/assets/svgs/heroicons/outline/shopping-cart.svg +3 -0
- data/app/assets/svgs/heroicons/outline/sort-ascending.svg +3 -0
- data/app/assets/svgs/heroicons/outline/sort-descending.svg +3 -0
- data/app/assets/svgs/heroicons/outline/sparkles.svg +3 -0
- data/app/assets/svgs/heroicons/outline/speakerphone.svg +3 -0
- data/app/assets/svgs/heroicons/outline/star.svg +3 -0
- data/app/assets/svgs/heroicons/outline/status-offline.svg +3 -0
- data/app/assets/svgs/heroicons/outline/status-online.svg +3 -0
- data/app/assets/svgs/heroicons/outline/stop.svg +4 -0
- data/app/assets/svgs/heroicons/outline/sun.svg +3 -0
- data/app/assets/svgs/heroicons/outline/support.svg +3 -0
- data/app/assets/svgs/heroicons/outline/switch-horizontal.svg +3 -0
- data/app/assets/svgs/heroicons/outline/switch-vertical.svg +3 -0
- data/app/assets/svgs/heroicons/outline/table.svg +3 -0
- data/app/assets/svgs/heroicons/outline/tag.svg +3 -0
- data/app/assets/svgs/heroicons/outline/template.svg +3 -0
- data/app/assets/svgs/heroicons/outline/terminal.svg +3 -0
- data/app/assets/svgs/heroicons/outline/thumb-down.svg +3 -0
- data/app/assets/svgs/heroicons/outline/thumb-up.svg +3 -0
- data/app/assets/svgs/heroicons/outline/ticket.svg +3 -0
- data/app/assets/svgs/heroicons/outline/translate.svg +3 -0
- data/app/assets/svgs/heroicons/outline/trash.svg +3 -0
- data/app/assets/svgs/heroicons/outline/trending-down.svg +3 -0
- data/app/assets/svgs/heroicons/outline/trending-up.svg +3 -0
- data/app/assets/svgs/heroicons/outline/truck.svg +4 -0
- data/app/assets/svgs/heroicons/outline/upload.svg +3 -0
- data/app/assets/svgs/heroicons/outline/user-add.svg +3 -0
- data/app/assets/svgs/heroicons/outline/user-circle.svg +3 -0
- data/app/assets/svgs/heroicons/outline/user-group.svg +3 -0
- data/app/assets/svgs/heroicons/outline/user-remove.svg +3 -0
- data/app/assets/svgs/heroicons/outline/user.svg +3 -0
- data/app/assets/svgs/heroicons/outline/users.svg +3 -0
- data/app/assets/svgs/heroicons/outline/variable.svg +3 -0
- data/app/assets/svgs/heroicons/outline/video-camera.svg +3 -0
- data/app/assets/svgs/heroicons/outline/view-boards.svg +3 -0
- data/app/assets/svgs/heroicons/outline/view-grid-add.svg +3 -0
- data/app/assets/svgs/heroicons/outline/view-grid.svg +3 -0
- data/app/assets/svgs/heroicons/outline/view-list.svg +3 -0
- data/app/assets/svgs/heroicons/outline/volume-off.svg +4 -0
- data/app/assets/svgs/heroicons/outline/volume-up.svg +3 -0
- data/app/assets/svgs/heroicons/outline/wifi.svg +3 -0
- data/app/assets/svgs/heroicons/outline/x-circle.svg +3 -0
- data/app/assets/svgs/heroicons/outline/x.svg +3 -0
- data/app/assets/svgs/heroicons/outline/zoom-in.svg +3 -0
- data/app/assets/svgs/heroicons/outline/zoom-out.svg +3 -0
- data/app/assets/svgs/heroicons/solid/academic-cap.svg +3 -0
- data/app/assets/svgs/heroicons/solid/adjustments.svg +3 -0
- data/app/assets/svgs/heroicons/solid/annotation.svg +3 -0
- data/app/assets/svgs/heroicons/solid/archive.svg +4 -0
- data/app/assets/svgs/heroicons/solid/arrow-circle-down.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-circle-left.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-circle-right.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-circle-up.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-down.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-left.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-narrow-down.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-narrow-left.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-narrow-right.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-narrow-up.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-right.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-sm-down.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-sm-left.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-sm-right.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-sm-up.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrow-up.svg +3 -0
- data/app/assets/svgs/heroicons/solid/arrows-expand.svg +3 -0
- data/app/assets/svgs/heroicons/solid/at-symbol.svg +3 -0
- data/app/assets/svgs/heroicons/solid/backspace.svg +3 -0
- data/app/assets/svgs/heroicons/solid/badge-check.svg +3 -0
- data/app/assets/svgs/heroicons/solid/ban.svg +3 -0
- data/app/assets/svgs/heroicons/solid/beaker.svg +3 -0
- data/app/assets/svgs/heroicons/solid/bell.svg +3 -0
- data/app/assets/svgs/heroicons/solid/book-open.svg +3 -0
- data/app/assets/svgs/heroicons/solid/bookmark-alt.svg +3 -0
- data/app/assets/svgs/heroicons/solid/bookmark.svg +3 -0
- data/app/assets/svgs/heroicons/solid/briefcase.svg +4 -0
- data/app/assets/svgs/heroicons/solid/cake.svg +3 -0
- data/app/assets/svgs/heroicons/solid/calculator.svg +3 -0
- data/app/assets/svgs/heroicons/solid/calendar.svg +3 -0
- data/app/assets/svgs/heroicons/solid/camera.svg +3 -0
- data/app/assets/svgs/heroicons/solid/cash.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chart-bar.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chart-pie.svg +4 -0
- data/app/assets/svgs/heroicons/solid/chart-square-bar.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chat-alt-2.svg +4 -0
- data/app/assets/svgs/heroicons/solid/chat-alt.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chat.svg +3 -0
- data/app/assets/svgs/heroicons/solid/check-circle.svg +3 -0
- data/app/assets/svgs/heroicons/solid/check.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chevron-double-down.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chevron-double-left.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chevron-double-right.svg +4 -0
- data/app/assets/svgs/heroicons/solid/chevron-double-up.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chevron-down.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chevron-left.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chevron-right.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chevron-up.svg +3 -0
- data/app/assets/svgs/heroicons/solid/chip.svg +4 -0
- data/app/assets/svgs/heroicons/solid/clipboard-check.svg +4 -0
- data/app/assets/svgs/heroicons/solid/clipboard-copy.svg +4 -0
- data/app/assets/svgs/heroicons/solid/clipboard-list.svg +4 -0
- data/app/assets/svgs/heroicons/solid/clipboard.svg +4 -0
- data/app/assets/svgs/heroicons/solid/clock.svg +3 -0
- data/app/assets/svgs/heroicons/solid/cloud-download.svg +3 -0
- data/app/assets/svgs/heroicons/solid/cloud-upload.svg +4 -0
- data/app/assets/svgs/heroicons/solid/cloud.svg +3 -0
- data/app/assets/svgs/heroicons/solid/code.svg +3 -0
- data/app/assets/svgs/heroicons/solid/cog.svg +3 -0
- data/app/assets/svgs/heroicons/solid/collection.svg +3 -0
- data/app/assets/svgs/heroicons/solid/color-swatch.svg +3 -0
- data/app/assets/svgs/heroicons/solid/credit-card.svg +4 -0
- data/app/assets/svgs/heroicons/solid/cube-transparent.svg +3 -0
- data/app/assets/svgs/heroicons/solid/cube.svg +3 -0
- data/app/assets/svgs/heroicons/solid/currency-bangladeshi.svg +3 -0
- data/app/assets/svgs/heroicons/solid/currency-dollar.svg +4 -0
- data/app/assets/svgs/heroicons/solid/currency-euro.svg +3 -0
- data/app/assets/svgs/heroicons/solid/currency-pound.svg +3 -0
- data/app/assets/svgs/heroicons/solid/currency-rupee.svg +3 -0
- data/app/assets/svgs/heroicons/solid/currency-yen.svg +3 -0
- data/app/assets/svgs/heroicons/solid/cursor-click.svg +3 -0
- data/app/assets/svgs/heroicons/solid/database.svg +5 -0
- data/app/assets/svgs/heroicons/solid/desktop-computer.svg +3 -0
- data/app/assets/svgs/heroicons/solid/device-mobile.svg +3 -0
- data/app/assets/svgs/heroicons/solid/device-tablet.svg +3 -0
- data/app/assets/svgs/heroicons/solid/document-add.svg +3 -0
- data/app/assets/svgs/heroicons/solid/document-download.svg +3 -0
- data/app/assets/svgs/heroicons/solid/document-duplicate.svg +4 -0
- data/app/assets/svgs/heroicons/solid/document-remove.svg +3 -0
- data/app/assets/svgs/heroicons/solid/document-report.svg +3 -0
- data/app/assets/svgs/heroicons/solid/document-search.svg +4 -0
- data/app/assets/svgs/heroicons/solid/document-text.svg +3 -0
- data/app/assets/svgs/heroicons/solid/document.svg +3 -0
- data/app/assets/svgs/heroicons/solid/dots-circle-horizontal.svg +3 -0
- data/app/assets/svgs/heroicons/solid/dots-horizontal.svg +3 -0
- data/app/assets/svgs/heroicons/solid/dots-vertical.svg +3 -0
- data/app/assets/svgs/heroicons/solid/download.svg +3 -0
- data/app/assets/svgs/heroicons/solid/duplicate.svg +4 -0
- data/app/assets/svgs/heroicons/solid/emoji-happy.svg +3 -0
- data/app/assets/svgs/heroicons/solid/emoji-sad.svg +3 -0
- data/app/assets/svgs/heroicons/solid/exclamation-circle.svg +3 -0
- data/app/assets/svgs/heroicons/solid/exclamation.svg +3 -0
- data/app/assets/svgs/heroicons/solid/external-link.svg +4 -0
- data/app/assets/svgs/heroicons/solid/eye-off.svg +4 -0
- data/app/assets/svgs/heroicons/solid/eye.svg +4 -0
- data/app/assets/svgs/heroicons/solid/fast-forward.svg +3 -0
- data/app/assets/svgs/heroicons/solid/film.svg +3 -0
- data/app/assets/svgs/heroicons/solid/filter.svg +3 -0
- data/app/assets/svgs/heroicons/solid/finger-print.svg +5 -0
- data/app/assets/svgs/heroicons/solid/fire.svg +3 -0
- data/app/assets/svgs/heroicons/solid/flag.svg +3 -0
- data/app/assets/svgs/heroicons/solid/folder-add.svg +3 -0
- data/app/assets/svgs/heroicons/solid/folder-download.svg +3 -0
- data/app/assets/svgs/heroicons/solid/folder-open.svg +4 -0
- data/app/assets/svgs/heroicons/solid/folder-remove.svg +3 -0
- data/app/assets/svgs/heroicons/solid/folder.svg +3 -0
- data/app/assets/svgs/heroicons/solid/gift.svg +4 -0
- data/app/assets/svgs/heroicons/solid/globe-alt.svg +3 -0
- data/app/assets/svgs/heroicons/solid/globe.svg +3 -0
- data/app/assets/svgs/heroicons/solid/hand.svg +3 -0
- data/app/assets/svgs/heroicons/solid/hashtag.svg +3 -0
- data/app/assets/svgs/heroicons/solid/heart.svg +3 -0
- data/app/assets/svgs/heroicons/solid/home.svg +3 -0
- data/app/assets/svgs/heroicons/solid/identification.svg +3 -0
- data/app/assets/svgs/heroicons/solid/inbox-in.svg +4 -0
- data/app/assets/svgs/heroicons/solid/inbox.svg +3 -0
- data/app/assets/svgs/heroicons/solid/information-circle.svg +3 -0
- data/app/assets/svgs/heroicons/solid/key.svg +3 -0
- data/app/assets/svgs/heroicons/solid/library.svg +3 -0
- data/app/assets/svgs/heroicons/solid/light-bulb.svg +3 -0
- data/app/assets/svgs/heroicons/solid/lightning-bolt.svg +3 -0
- data/app/assets/svgs/heroicons/solid/link.svg +3 -0
- data/app/assets/svgs/heroicons/solid/location-marker.svg +3 -0
- data/app/assets/svgs/heroicons/solid/lock-closed.svg +3 -0
- data/app/assets/svgs/heroicons/solid/lock-open.svg +3 -0
- data/app/assets/svgs/heroicons/solid/login.svg +3 -0
- data/app/assets/svgs/heroicons/solid/logout.svg +3 -0
- data/app/assets/svgs/heroicons/solid/mail-open.svg +3 -0
- data/app/assets/svgs/heroicons/solid/mail.svg +4 -0
- data/app/assets/svgs/heroicons/solid/map.svg +3 -0
- data/app/assets/svgs/heroicons/solid/menu-alt-1.svg +3 -0
- data/app/assets/svgs/heroicons/solid/menu-alt-2.svg +3 -0
- data/app/assets/svgs/heroicons/solid/menu-alt-3.svg +3 -0
- data/app/assets/svgs/heroicons/solid/menu-alt-4.svg +3 -0
- data/app/assets/svgs/heroicons/solid/menu.svg +3 -0
- data/app/assets/svgs/heroicons/solid/microphone.svg +3 -0
- data/app/assets/svgs/heroicons/solid/minus-circle.svg +3 -0
- data/app/assets/svgs/heroicons/solid/minus-sm.svg +3 -0
- data/app/assets/svgs/heroicons/solid/minus.svg +3 -0
- data/app/assets/svgs/heroicons/solid/moon.svg +3 -0
- data/app/assets/svgs/heroicons/solid/music-note.svg +3 -0
- data/app/assets/svgs/heroicons/solid/newspaper.svg +4 -0
- data/app/assets/svgs/heroicons/solid/office-building.svg +3 -0
- data/app/assets/svgs/heroicons/solid/paper-airplane.svg +3 -0
- data/app/assets/svgs/heroicons/solid/paper-clip.svg +3 -0
- data/app/assets/svgs/heroicons/solid/pause.svg +3 -0
- data/app/assets/svgs/heroicons/solid/pencil-alt.svg +4 -0
- data/app/assets/svgs/heroicons/solid/pencil.svg +3 -0
- data/app/assets/svgs/heroicons/solid/phone-incoming.svg +4 -0
- data/app/assets/svgs/heroicons/solid/phone-missed-call.svg +4 -0
- data/app/assets/svgs/heroicons/solid/phone-outgoing.svg +4 -0
- data/app/assets/svgs/heroicons/solid/phone.svg +3 -0
- data/app/assets/svgs/heroicons/solid/photograph.svg +3 -0
- data/app/assets/svgs/heroicons/solid/play.svg +3 -0
- data/app/assets/svgs/heroicons/solid/plus-circle.svg +3 -0
- data/app/assets/svgs/heroicons/solid/plus-sm.svg +3 -0
- data/app/assets/svgs/heroicons/solid/plus.svg +3 -0
- data/app/assets/svgs/heroicons/solid/presentation-chart-bar.svg +3 -0
- data/app/assets/svgs/heroicons/solid/presentation-chart-line.svg +3 -0
- data/app/assets/svgs/heroicons/solid/printer.svg +3 -0
- data/app/assets/svgs/heroicons/solid/puzzle.svg +3 -0
- data/app/assets/svgs/heroicons/solid/qrcode.svg +4 -0
- data/app/assets/svgs/heroicons/solid/question-mark-circle.svg +3 -0
- data/app/assets/svgs/heroicons/solid/receipt-refund.svg +3 -0
- data/app/assets/svgs/heroicons/solid/receipt-tax.svg +3 -0
- data/app/assets/svgs/heroicons/solid/refresh.svg +3 -0
- data/app/assets/svgs/heroicons/solid/reply.svg +3 -0
- data/app/assets/svgs/heroicons/solid/rewind.svg +3 -0
- data/app/assets/svgs/heroicons/solid/rss.svg +4 -0
- data/app/assets/svgs/heroicons/solid/save-as.svg +4 -0
- data/app/assets/svgs/heroicons/solid/save.svg +3 -0
- data/app/assets/svgs/heroicons/solid/scale.svg +3 -0
- data/app/assets/svgs/heroicons/solid/scissors.svg +4 -0
- data/app/assets/svgs/heroicons/solid/search-circle.svg +4 -0
- data/app/assets/svgs/heroicons/solid/search.svg +3 -0
- data/app/assets/svgs/heroicons/solid/selector.svg +3 -0
- data/app/assets/svgs/heroicons/solid/server.svg +3 -0
- data/app/assets/svgs/heroicons/solid/share.svg +3 -0
- data/app/assets/svgs/heroicons/solid/shield-check.svg +3 -0
- data/app/assets/svgs/heroicons/solid/shield-exclamation.svg +3 -0
- data/app/assets/svgs/heroicons/solid/shopping-bag.svg +3 -0
- data/app/assets/svgs/heroicons/solid/shopping-cart.svg +3 -0
- data/app/assets/svgs/heroicons/solid/sort-ascending.svg +3 -0
- data/app/assets/svgs/heroicons/solid/sort-descending.svg +3 -0
- data/app/assets/svgs/heroicons/solid/sparkles.svg +3 -0
- data/app/assets/svgs/heroicons/solid/speakerphone.svg +3 -0
- data/app/assets/svgs/heroicons/solid/star.svg +3 -0
- data/app/assets/svgs/heroicons/solid/status-offline.svg +3 -0
- data/app/assets/svgs/heroicons/solid/status-online.svg +3 -0
- data/app/assets/svgs/heroicons/solid/stop.svg +3 -0
- data/app/assets/svgs/heroicons/solid/sun.svg +3 -0
- data/app/assets/svgs/heroicons/solid/support.svg +3 -0
- data/app/assets/svgs/heroicons/solid/switch-horizontal.svg +3 -0
- data/app/assets/svgs/heroicons/solid/switch-vertical.svg +3 -0
- data/app/assets/svgs/heroicons/solid/table.svg +3 -0
- data/app/assets/svgs/heroicons/solid/tag.svg +3 -0
- data/app/assets/svgs/heroicons/solid/template.svg +3 -0
- data/app/assets/svgs/heroicons/solid/terminal.svg +3 -0
- data/app/assets/svgs/heroicons/solid/thumb-down.svg +3 -0
- data/app/assets/svgs/heroicons/solid/thumb-up.svg +3 -0
- data/app/assets/svgs/heroicons/solid/ticket.svg +3 -0
- data/app/assets/svgs/heroicons/solid/translate.svg +3 -0
- data/app/assets/svgs/heroicons/solid/trash.svg +3 -0
- data/app/assets/svgs/heroicons/solid/trending-down.svg +3 -0
- data/app/assets/svgs/heroicons/solid/trending-up.svg +3 -0
- data/app/assets/svgs/heroicons/solid/truck.svg +4 -0
- data/app/assets/svgs/heroicons/solid/upload.svg +3 -0
- data/app/assets/svgs/heroicons/solid/user-add.svg +3 -0
- data/app/assets/svgs/heroicons/solid/user-circle.svg +3 -0
- data/app/assets/svgs/heroicons/solid/user-group.svg +3 -0
- data/app/assets/svgs/heroicons/solid/user-remove.svg +3 -0
- data/app/assets/svgs/heroicons/solid/user.svg +3 -0
- data/app/assets/svgs/heroicons/solid/users.svg +3 -0
- data/app/assets/svgs/heroicons/solid/variable.svg +3 -0
- data/app/assets/svgs/heroicons/solid/video-camera.svg +3 -0
- data/app/assets/svgs/heroicons/solid/view-boards.svg +3 -0
- data/app/assets/svgs/heroicons/solid/view-grid-add.svg +3 -0
- data/app/assets/svgs/heroicons/solid/view-grid.svg +3 -0
- data/app/assets/svgs/heroicons/solid/view-list.svg +3 -0
- data/app/assets/svgs/heroicons/solid/volume-off.svg +3 -0
- data/app/assets/svgs/heroicons/solid/volume-up.svg +3 -0
- data/app/assets/svgs/heroicons/solid/wifi.svg +3 -0
- data/app/assets/svgs/{x-circle-sm.svg → heroicons/solid/x-circle.svg} +2 -2
- data/app/assets/svgs/heroicons/solid/x.svg +3 -0
- data/app/assets/svgs/heroicons/solid/zoom-in.svg +4 -0
- data/app/assets/svgs/heroicons/solid/zoom-out.svg +4 -0
- data/app/assets/svgs/logout.svg +3 -0
- data/app/assets/svgs/menu-back.svg +4 -0
- data/app/assets/svgs/menu.svg +3 -0
- data/app/assets/svgs/resources-icon.svg +13 -0
- data/app/assets/svgs/table-empty-state.svg +57 -0
- data/app/assets/svgs/table-view-type.svg +6 -0
- data/app/assets/svgs/three-dots.svg +5 -0
- data/app/assets/svgs/tools-icon.svg +3 -0
- data/app/assets/svgs/trash.svg +7 -1
- data/app/assets/svgs/user-circle.svg +3 -0
- data/app/components/avo/actions_component.html.erb +43 -0
- data/app/components/avo/actions_component.rb +14 -0
- data/app/components/avo/alert_component.html.erb +25 -1
- data/app/components/avo/alert_component.rb +24 -0
- data/app/components/avo/button_component.html.erb +1 -0
- data/app/components/avo/button_component.rb +143 -0
- data/app/components/avo/card_component.html.erb +40 -0
- data/app/components/avo/card_component.rb +11 -0
- data/app/components/avo/common_field_wrapper_component.html.erb +15 -0
- data/app/components/avo/common_field_wrapper_component.rb +20 -0
- data/app/components/avo/dashboards/divider_component.html.erb +9 -0
- data/app/components/avo/dashboards/divider_component.rb +19 -0
- data/app/components/avo/edit/field_wrapper_component.html.erb +10 -19
- data/app/components/avo/edit/field_wrapper_component.rb +0 -8
- data/app/components/avo/empty_state_component.html.erb +12 -0
- data/app/components/avo/empty_state_component.rb +24 -0
- data/app/components/avo/fields/belongs_to_field/edit_component.html.erb +2 -1
- data/app/components/avo/fields/boolean_field/edit_component.html.erb +1 -1
- data/app/components/avo/fields/boolean_field/index_component.html.erb +1 -1
- data/app/components/avo/fields/boolean_group_field/edit_component.html.erb +1 -1
- data/app/components/avo/fields/common/boolean_check_component.html.erb +4 -4
- data/app/components/avo/fields/common/boolean_group_component.html.erb +2 -2
- data/app/components/avo/fields/common/files_list_viewer_component.html.erb +2 -2
- data/app/components/avo/fields/common/gravatar_viewer_component.html.erb +1 -1
- data/app/components/avo/fields/common/heading_component.html.erb +2 -2
- data/app/components/avo/fields/common/key_value_component.html.erb +2 -2
- data/app/components/avo/fields/common/single_file_viewer_component.html.erb +42 -23
- data/app/components/avo/fields/common/single_file_viewer_component.rb +34 -6
- data/app/components/avo/fields/common/status_viewer_component.html.erb +2 -2
- data/app/components/avo/fields/external_image_field/index_component.html.erb +1 -1
- data/app/components/avo/fields/file_field/edit_component.html.erb +1 -1
- data/app/components/avo/fields/file_field/show_component.html.erb +1 -1
- data/app/components/avo/fields/has_many_field/show_component.html.erb +1 -1
- data/app/components/avo/fields/has_one_field/show_component.html.erb +4 -4
- data/app/components/avo/fields/heading_field/edit_component.html.erb +1 -1
- data/app/components/avo/fields/heading_field/show_component.html.erb +1 -1
- data/app/components/avo/fields/trix_field/edit_component.html.erb +1 -0
- data/app/components/avo/filters_component.html.erb +37 -0
- data/app/components/avo/filters_component.rb +14 -0
- data/app/components/avo/{alerts_component.html.erb → flash_alerts_component.html.erb} +1 -1
- data/app/components/avo/flash_alerts_component.rb +9 -0
- data/app/components/avo/index/field_wrapper_component.html.erb +8 -2
- data/app/components/avo/index/field_wrapper_component.rb +2 -1
- data/app/components/avo/index/grid_item_component.html.erb +13 -10
- data/app/components/avo/index/ordering/buttons_component.rb +2 -0
- data/app/components/avo/index/resource_controls_component.html.erb +6 -5
- data/app/components/avo/index/resource_grid_component.html.erb +3 -3
- data/app/components/avo/index/resource_table_component.html.erb +10 -14
- data/app/components/avo/index/table_row_component.html.erb +1 -1
- data/app/components/avo/modal_component.html.erb +9 -7
- data/app/{views/avo/partials/_paginator.html.erb → components/avo/paginator_component.html.erb} +16 -16
- data/app/components/avo/paginator_component.rb +17 -0
- data/app/components/avo/panel_component.html.erb +21 -17
- data/app/components/avo/panel_component.rb +8 -2
- data/app/components/avo/profile_item_component.html.erb +3 -0
- data/app/components/avo/profile_item_component.rb +11 -0
- data/app/components/avo/resource_component.rb +1 -1
- data/app/components/avo/show/field_wrapper_component.html.erb +8 -15
- data/app/components/avo/show/field_wrapper_component.rb +0 -4
- data/app/components/avo/sidebar_component.html.erb +51 -0
- data/app/components/avo/sidebar_component.rb +19 -0
- data/app/components/avo/sidebar_heading_component.html.erb +3 -0
- data/app/components/avo/sidebar_heading_component.rb +11 -0
- data/app/components/avo/sidebar_item_component.html.erb +3 -0
- data/app/components/avo/sidebar_item_component.rb +10 -0
- data/app/components/avo/sidebar_profile_component.html.erb +36 -0
- data/app/components/avo/sidebar_profile_component.rb +43 -0
- data/app/components/avo/turbo_frame_wrapper_component.html.erb +8 -9
- data/app/components/avo/views/resource_edit_component.html.erb +16 -19
- data/app/components/avo/views/resource_index_component.html.erb +44 -35
- data/app/components/avo/views/resource_new_component.html.erb +18 -16
- data/app/components/avo/views/resource_show_component.html.erb +36 -34
- data/app/components/avo/views/resource_show_component.rb +2 -3
- data/app/controllers/avo/application_controller.rb +43 -12
- data/app/controllers/avo/{relations_controller.rb → associations_controller.rb} +1 -3
- data/app/controllers/avo/attachments_controller.rb +1 -5
- data/app/controllers/avo/base_controller.rb +20 -24
- data/app/controllers/avo/dashboards_controller.rb +28 -0
- data/app/controllers/avo/private_controller.rb +8 -0
- data/app/helpers/avo/application_helper.rb +29 -47
- data/app/helpers/avo/resources_helper.rb +2 -2
- data/app/helpers/avo/url_helpers.rb +5 -9
- data/app/javascript/avo.js +22 -2
- data/app/javascript/js/application.js +2 -1
- data/app/javascript/js/controllers/actions_picker_controller.js +12 -10
- data/app/javascript/js/controllers/dashboard_card_controller.js +33 -0
- data/app/javascript/js/controllers/item_selector_controller.js +8 -4
- data/app/javascript/js/controllers/mobile_controller.js +9 -0
- data/app/javascript/js/controllers/select_controller.js +23 -0
- data/app/javascript/js/controllers.js +6 -0
- data/app/views/avo/actions/show.html.erb +22 -17
- data/app/views/avo/{relations → associations}/new.html.erb +16 -6
- data/app/views/avo/base/_multiple_select_filter.html.erb +5 -1
- data/app/views/avo/base/_text_filter.html.erb +3 -1
- data/app/views/avo/base/show.html.erb +1 -1
- data/app/views/avo/dashboards/_chartkick_card.html.erb +3 -0
- data/app/views/avo/dashboards/_metric_card.html.erb +5 -0
- data/app/views/avo/dashboards/card.html.erb +3 -0
- data/app/views/avo/dashboards/show.html.erb +35 -0
- data/app/views/avo/home/index.html.erb +1 -5
- data/app/views/avo/partials/_custom_tools_alert.html.erb +2 -2
- data/app/views/avo/partials/_global_search.html.erb +3 -3
- data/app/views/avo/partials/_header.html.erb +1 -1
- data/app/views/avo/partials/_logo.html.erb +1 -1
- data/app/views/avo/partials/_navbar.html.erb +11 -0
- data/app/views/avo/partials/_resource_search.html.erb +1 -1
- data/app/views/avo/partials/_sortable_component.html.erb +1 -1
- data/app/views/avo/partials/_table_header.html.erb +4 -4
- data/app/views/avo/partials/_view_toggle_button.html.erb +36 -16
- data/app/views/avo/private/_links_and_buttons.html.erb +57 -0
- data/app/views/avo/private/design.html.erb +27 -0
- data/app/views/layouts/avo/application.html.erb +20 -31
- data/avo.gemspec +4 -2
- data/config/routes.rb +19 -11
- data/lib/avo/app.rb +30 -3
- data/lib/avo/base_resource.rb +6 -8
- data/lib/avo/dashboards/base_card.rb +151 -0
- data/lib/avo/dashboards/base_dashboard.rb +54 -0
- data/lib/avo/dashboards/base_divider.rb +23 -0
- data/lib/avo/dashboards/chartkick_card.rb +77 -0
- data/lib/avo/dashboards/metric_card.rb +9 -0
- data/lib/avo/dashboards/partial_card.rb +7 -0
- data/lib/avo/dynamic_router.rb +3 -0
- data/lib/avo/engine.rb +5 -1
- data/lib/avo/fields/date_field.rb +1 -1
- data/lib/avo/fields/gravatar_field.rb +2 -2
- data/lib/avo/hosts/dashboard_card.rb +21 -0
- data/lib/avo/hosts/ordering.rb +1 -1
- data/lib/avo/licensing/license.rb +4 -2
- data/lib/avo/licensing/pro_license.rb +2 -1
- data/lib/avo/version.rb +1 -1
- data/lib/avo.rb +24 -1
- data/lib/generators/avo/chartkick_card_generator.rb +16 -0
- data/lib/generators/avo/dashboard_generator.rb +16 -0
- data/lib/generators/avo/metric_card_generator.rb +16 -0
- data/lib/generators/avo/partial_card_generator.rb +17 -0
- data/lib/generators/avo/templates/cards/chartkick_card.tt +16 -0
- data/lib/generators/avo/templates/cards/chartkick_card_sample.tt +26 -0
- data/lib/generators/avo/templates/cards/metric_card.tt +8 -0
- data/lib/generators/avo/templates/cards/metric_card_sample.tt +38 -0
- data/lib/generators/avo/templates/cards/partial_card.tt +8 -0
- data/lib/generators/avo/templates/cards/partial_card_partial.tt +8 -0
- data/lib/generators/avo/templates/cards/partial_card_sample.tt +8 -0
- data/lib/generators/avo/templates/dashboards/dashboard.tt +9 -0
- data/lib/generators/avo/templates/locales/avo.en.yml +11 -4
- data/lib/generators/avo/templates/locales/avo.nb-NO.yml +5 -2
- data/lib/generators/avo/templates/locales/avo.pt-BR.yml +4 -2
- data/lib/generators/avo/templates/locales/avo.ro.yml +4 -1
- data/lib/generators/avo/templates/tool/sidebar_item.tt +1 -1
- data/public/avo-assets/avo.css +1300 -1121
- data/public/avo-assets/avo.js +348 -88688
- data/public/avo-assets/avo.js.map +3 -3
- data/public/avo-assets/fonts/inter-v7-latin-500.eot +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-500.svg +351 -0
- data/public/avo-assets/fonts/inter-v7-latin-500.ttf +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-500.woff +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-500.woff2 +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-600.eot +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-600.svg +351 -0
- data/public/avo-assets/fonts/inter-v7-latin-600.ttf +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-600.woff +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-600.woff2 +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-700.eot +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-700.svg +352 -0
- data/public/avo-assets/fonts/inter-v7-latin-700.ttf +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-700.woff +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-700.woff2 +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-regular.eot +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-regular.svg +351 -0
- data/public/avo-assets/fonts/inter-v7-latin-regular.ttf +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-regular.woff +0 -0
- data/public/avo-assets/fonts/inter-v7-latin-regular.woff2 +0 -0
- data/public/avo-assets/logo-on-white.png +0 -0
- data/public/avo-assets/logo.png +0 -0
- metadata +579 -50
- data/app/assets/builds/action_cable.js +0 -2
- data/app/assets/builds/action_cable.js.map +0 -7
- data/app/assets/builds/application.js +0 -2
- data/app/assets/builds/application.js.map +0 -7
- data/app/assets/builds/avo.css +0 -8610
- data/app/assets/builds/avo.js +0 -88762
- data/app/assets/builds/avo.js.map +0 -7
- data/app/assets/builds/avo_custom.js +0 -6
- data/app/assets/builds/avo_custom.js.map +0 -7
- data/app/assets/images/avo/logo.png +0 -0
- data/app/assets/svgs/check-circle-sm.svg +0 -3
- data/app/components/avo/alerts_component.rb +0 -5
- data/app/components/avo/fields/common/multiple_file_viewer_component.html.erb +0 -35
- data/app/components/avo/fields/common/multiple_file_viewer_component.rb +0 -15
- data/app/components/avo/navigation_heading_component.html.erb +0 -3
- data/app/components/avo/navigation_heading_component.rb +0 -7
- data/app/components/avo/navigation_link_component.html.erb +0 -3
- data/app/components/avo/navigation_link_component.rb +0 -11
- data/app/javascript/js/toastr.js +0 -10
- data/app/views/avo/attachments/show.html.erb +0 -14
- data/app/views/avo/base/_actions.html.erb +0 -36
- data/app/views/avo/base/_filters.html.erb +0 -34
- data/app/views/avo/partials/_a_button.html.erb +0 -7
- data/app/views/avo/partials/_a_link.html.erb +0 -7
- data/app/views/avo/partials/_empty_state.html.erb +0 -17
- data/app/views/avo/partials/_profile_dropdown.html.erb +0 -25
- data/app/views/avo/sidebar/_sidebar.html.erb +0 -31
- data/lib/avo/services/panel_service.rb +0 -27
- data/public/avo-assets/fonts/nunito-v16-latin-700.eot +0 -0
- data/public/avo-assets/fonts/nunito-v16-latin-700.svg +0 -388
- data/public/avo-assets/fonts/nunito-v16-latin-700.ttf +0 -0
- data/public/avo-assets/fonts/nunito-v16-latin-700.woff +0 -0
- data/public/avo-assets/fonts/nunito-v16-latin-700.woff2 +0 -0
- data/public/avo-assets/fonts/nunito-v16-latin-regular.eot +0 -0
- data/public/avo-assets/fonts/nunito-v16-latin-regular.svg +0 -380
- data/public/avo-assets/fonts/nunito-v16-latin-regular.ttf +0 -0
- data/public/avo-assets/fonts/nunito-v16-latin-regular.woff +0 -0
- data/public/avo-assets/fonts/nunito-v16-latin-regular.woff2 +0 -0
@@ -1 +1,25 @@
|
|
1
|
-
<div data-controller="
|
1
|
+
<div data-controller="alert"
|
2
|
+
data-alert-dismiss-after-value="5000"
|
3
|
+
data-alert-remove-delay-value="0"
|
4
|
+
class="<%= classes %>"
|
5
|
+
>
|
6
|
+
<div class="px-2">
|
7
|
+
<div class="flex h-full">
|
8
|
+
<div class="flex items-center min-h-full">
|
9
|
+
<%= helpers.svg icon, class: "h-6" %>
|
10
|
+
</div>
|
11
|
+
<div class="ml-3 w-0 flex-1 pt-0.5">
|
12
|
+
<p class="text-sm leading-5 font-semibold">
|
13
|
+
<%= message %>
|
14
|
+
</p>
|
15
|
+
</div>
|
16
|
+
<div class="ml-4 flex-shrink-0 flex">
|
17
|
+
<button data-action="alert#close" class="inline-flex text-white focus:outline-none focus:text-gray-300 transition ease-in-out duration-150">
|
18
|
+
<svg class="h-5 w-5" viewBox="0 0 20 20" fill="currentColor">
|
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
|
+
</svg>
|
21
|
+
</button>
|
22
|
+
</div>
|
23
|
+
</div>
|
24
|
+
</div>
|
25
|
+
</div>
|
@@ -1,6 +1,8 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
class Avo::AlertComponent < ViewComponent::Base
|
4
|
+
include Avo::ApplicationHelper
|
5
|
+
|
4
6
|
attr_reader :type
|
5
7
|
attr_reader :message
|
6
8
|
|
@@ -8,4 +10,26 @@ class Avo::AlertComponent < ViewComponent::Base
|
|
8
10
|
@type = type
|
9
11
|
@message = message
|
10
12
|
end
|
13
|
+
|
14
|
+
def icon
|
15
|
+
return 'x-circle' if is_error?
|
16
|
+
|
17
|
+
'check-circle'
|
18
|
+
end
|
19
|
+
|
20
|
+
def classes
|
21
|
+
result = "max-w-sm w-full shadow-lg rounded px-4 py-3 rounded relative border text-white pointer-events-auto"
|
22
|
+
|
23
|
+
if is_error?
|
24
|
+
result += " bg-red-400 border-red-700"
|
25
|
+
else
|
26
|
+
result += " bg-green-400 border-green-700"
|
27
|
+
end
|
28
|
+
|
29
|
+
result
|
30
|
+
end
|
31
|
+
|
32
|
+
def is_error?
|
33
|
+
type.to_sym == :error
|
34
|
+
end
|
11
35
|
end
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= output %>
|
@@ -0,0 +1,143 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# A button/link can have the following settings:
|
4
|
+
# style: primary/secondary/ternary
|
5
|
+
# size: :xs :sm, :md, :lg
|
6
|
+
class Avo::ButtonComponent < ViewComponent::Base
|
7
|
+
def initialize(path = nil, size: :md, style: :outline, color: :gray, icon: nil, icon_class: "", is_link: false, rounded: true, compact: false, **args)
|
8
|
+
# Main settings
|
9
|
+
@size = size
|
10
|
+
@style = style
|
11
|
+
@color = color
|
12
|
+
|
13
|
+
# Other things that appear in the button
|
14
|
+
@path = path
|
15
|
+
@icon = icon
|
16
|
+
@icon_class = icon_class
|
17
|
+
@rounded = rounded
|
18
|
+
@compact = compact
|
19
|
+
|
20
|
+
# Other settings
|
21
|
+
@class = args[:class]
|
22
|
+
@is_link = is_link
|
23
|
+
@args = args || {}
|
24
|
+
end
|
25
|
+
|
26
|
+
def args
|
27
|
+
if @args[:spinner]
|
28
|
+
@args[:"data-controller"] = "loading-button"
|
29
|
+
end
|
30
|
+
|
31
|
+
@args[:class] = button_classes
|
32
|
+
|
33
|
+
@args
|
34
|
+
end
|
35
|
+
|
36
|
+
def button_classes
|
37
|
+
classes = "button-component inline-flex flex-grow-0 items-center text-sm font-semibold leading-6 fill-current whitespace-nowrap transition duration-100 transform transition duration-100 cursor-pointer disabled:cursor-not-allowed disabled:opacity-30 border justify-center active:outline active:outline-1 #{@class}"
|
38
|
+
|
39
|
+
classes += " rounded" if @rounded.present?
|
40
|
+
|
41
|
+
classes += style_classes
|
42
|
+
|
43
|
+
classes += @compact ? " px-1" : " px-4" # Same horizontal padding on all sizes
|
44
|
+
classes += spacing_classes
|
45
|
+
|
46
|
+
classes
|
47
|
+
end
|
48
|
+
|
49
|
+
def is_link?
|
50
|
+
@is_link
|
51
|
+
end
|
52
|
+
|
53
|
+
def full_content
|
54
|
+
result = ""
|
55
|
+
icon_classes = @icon_class
|
56
|
+
icon_classes += full_content_icon_classes
|
57
|
+
|
58
|
+
result += helpers.svg(@icon, class: icon_classes) if @icon.present?
|
59
|
+
result += "<span class='w-0 m-0'> </span>"
|
60
|
+
if content.present?
|
61
|
+
result += "<span>#{content}</span>"
|
62
|
+
end
|
63
|
+
|
64
|
+
result.html_safe
|
65
|
+
end
|
66
|
+
|
67
|
+
def output
|
68
|
+
if is_link?
|
69
|
+
output_link
|
70
|
+
else
|
71
|
+
output_button
|
72
|
+
end
|
73
|
+
end
|
74
|
+
|
75
|
+
def output_link
|
76
|
+
link_to @path, **args do
|
77
|
+
full_content
|
78
|
+
end
|
79
|
+
end
|
80
|
+
|
81
|
+
def output_button
|
82
|
+
if @args[:method].present?
|
83
|
+
button_to @args[:url], **args do
|
84
|
+
full_content
|
85
|
+
end
|
86
|
+
else
|
87
|
+
button_tag(**args) do
|
88
|
+
full_content
|
89
|
+
end
|
90
|
+
end
|
91
|
+
end
|
92
|
+
|
93
|
+
private
|
94
|
+
|
95
|
+
def spacing_classes
|
96
|
+
case @size.to_sym
|
97
|
+
when :xs
|
98
|
+
" py-0"
|
99
|
+
when :sm
|
100
|
+
" py-1"
|
101
|
+
when :md
|
102
|
+
" py-2"
|
103
|
+
when :lg
|
104
|
+
" py-3"
|
105
|
+
else
|
106
|
+
""
|
107
|
+
end
|
108
|
+
end
|
109
|
+
|
110
|
+
def style_classes
|
111
|
+
case @style
|
112
|
+
when :primary
|
113
|
+
" bg-primary-500 text-white border-primary-500 hover:bg-primary-600 hover:border-primary-600 active:border-primary-700 active:outline-primary-700 active:bg-primary-600"
|
114
|
+
when :outline
|
115
|
+
" bg-white text-#{@color}-500 border-#{@color}-500 hover:bg-#{@color}-100 active:bg-#{@color}-100 active:border-#{@color}-500 active:outline-#{@color}-500"
|
116
|
+
else
|
117
|
+
""
|
118
|
+
end
|
119
|
+
end
|
120
|
+
|
121
|
+
def full_content_icon_classes
|
122
|
+
icon_classes = ""
|
123
|
+
|
124
|
+
case @size
|
125
|
+
when :xs
|
126
|
+
icon_classes += " h-4"
|
127
|
+
# When icon is solo we need to add an offset
|
128
|
+
icon_classes += " my-1" if content.blank?
|
129
|
+
when :sm
|
130
|
+
icon_classes += " h-4"
|
131
|
+
# When icon is solo we need to add an offset
|
132
|
+
icon_classes += " my-1" if content.blank?
|
133
|
+
when :md
|
134
|
+
icon_classes += " h-5"
|
135
|
+
# When icon is solo we need to add an offset
|
136
|
+
icon_classes += " my-0.5" if content.blank?
|
137
|
+
when :lg
|
138
|
+
icon_classes += " h-6"
|
139
|
+
end
|
140
|
+
|
141
|
+
icon_classes
|
142
|
+
end
|
143
|
+
end
|
@@ -0,0 +1,40 @@
|
|
1
|
+
<div class="relative flex-1 flex flex-col justify-between h-full" data-controller="dashboard-card" data-dashboard-card-target="card" data-refresh-every="<%= @card.refresh_every %>" data-card-id="<%= @card.id %>">
|
2
|
+
<% if @card.class.display_header %>
|
3
|
+
<div class="px-4 pt-4">
|
4
|
+
<div class="flex justify-between items-center min-h-6">
|
5
|
+
<div class="text-base font-bold text-gray-700 leading-none">
|
6
|
+
<%= @card.label %>
|
7
|
+
</div>
|
8
|
+
<div data-controller="select">
|
9
|
+
<% if @card.type == :metric && @card.parsed_ranges.present? %>
|
10
|
+
<%= select_tag "#{@card.id}_range", options_for_select(@card.parsed_ranges, @card.range),
|
11
|
+
class: 'appearance-none inline-flex bg-blue-gray-100 disabled:bg-blue-gray-300 disabled:cursor-not-allowed focus:bg-white text-sm text-blue-gray-700 disabled:text-blue-gray-700 leading-none rounded-md py-px px-2 leading-tight border outline-none outline w-24',
|
12
|
+
data: {
|
13
|
+
target: 'select',
|
14
|
+
action: 'change->select#onChange'
|
15
|
+
}
|
16
|
+
%>
|
17
|
+
<% end %>
|
18
|
+
</div>
|
19
|
+
</div>
|
20
|
+
</div>
|
21
|
+
<% end %>
|
22
|
+
<% if @card.type == :chartkick %>
|
23
|
+
<%= render 'chartkick_card', card: @card %>
|
24
|
+
<% elsif @card.type === :partial %>
|
25
|
+
<%= render @card.class.partial %>
|
26
|
+
<% elsif @card.type === :metric %>
|
27
|
+
<div class="flex-1 flex px-4 pb-4">
|
28
|
+
<%= render 'metric_card', card: @card %>
|
29
|
+
</div>
|
30
|
+
<% end %>
|
31
|
+
<% if @card.description %>
|
32
|
+
<div class="absolute inset-auto bottom-0 right-0 mb-4 mr-4">
|
33
|
+
<%= helpers.svg 'heroicons/solid/information-circle',
|
34
|
+
class: 'h-4 text-gray-500 cursor-pointer',
|
35
|
+
title: @card.description,
|
36
|
+
'data-tippy': 'tooltip',
|
37
|
+
'data-target': 'card-description' %>
|
38
|
+
</div>
|
39
|
+
<% end %>
|
40
|
+
</div>
|
@@ -0,0 +1,15 @@
|
|
1
|
+
<div class="flex flex-col md:flex-row md:items-center pb-2 md:pb-0 leading-tight <%= @classes %> min-h-14" data-field-id="<%= @field.id %>" data-field-type="<%= @field.type %>">
|
2
|
+
<div class="pt-4 md:pt-0 md:h-14 flex self-start items-center text-slate-800">
|
3
|
+
<div class="<% if @displayed_in_modal %> md:w-48 <% else %> md:w-64 px-6 md:px-6 <% end %> w-48 flex uppercase font-semibold text-gray-500 text-sm" data-slot="label">
|
4
|
+
<% if @form.present? %>
|
5
|
+
<%= @form.label @field.id, label %>
|
6
|
+
<% else %>
|
7
|
+
<%= @field.name %>
|
8
|
+
<% end %>
|
9
|
+
<% if @field.required %> <span class="text-red-600 ml-1">*</span> <% end %>
|
10
|
+
</div>
|
11
|
+
</div>
|
12
|
+
<div class="flex-1 flex flex-row md:min-h-inherit py-2 <% unless @displayed_in_modal %> px-6 <% end %>">
|
13
|
+
<%= content %>
|
14
|
+
</div>
|
15
|
+
</div>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
class Avo::CommonFieldWrapperComponent < ViewComponent::Base
|
4
|
+
def initialize(field: nil, dash_if_blank: true, full_width: false, displayed_in_modal: false, form: nil, resource: {}, label: nil, **args)
|
5
|
+
@field = field
|
6
|
+
@dash_if_blank = dash_if_blank
|
7
|
+
@classes = args[:class].present? ? args[:class] : ""
|
8
|
+
@args = args
|
9
|
+
@displayed_in_modal = displayed_in_modal
|
10
|
+
@form = form
|
11
|
+
@resource = resource
|
12
|
+
@model = resource.present? ? resource.model : nil
|
13
|
+
@full_width = full_width
|
14
|
+
@label = label
|
15
|
+
end
|
16
|
+
|
17
|
+
def label
|
18
|
+
@label || @field.name
|
19
|
+
end
|
20
|
+
end
|
@@ -0,0 +1,9 @@
|
|
1
|
+
<% if invisible? %>
|
2
|
+
<div class="relative col-span-full gap-0"></div>
|
3
|
+
<% else %>
|
4
|
+
<div class="relative col-span-full border-t border-gray-300 my-4">
|
5
|
+
<% if label.present? %>
|
6
|
+
<div class="absolute inset-auto -translate-y-1/2 -translate-x-1/2 ml-1/2 z-20 text-xs font-semibold uppercase leading-none text-gray-500 bg-application px-2"><%= label %></div>
|
7
|
+
<% end %>
|
8
|
+
</div>
|
9
|
+
<% end %>
|
@@ -0,0 +1,19 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
class Avo::Dashboards::DividerComponent < ViewComponent::Base
|
4
|
+
attr_reader :divider
|
5
|
+
|
6
|
+
delegate :label, to: :divider
|
7
|
+
|
8
|
+
def initialize(divider: nil)
|
9
|
+
@divider = divider
|
10
|
+
end
|
11
|
+
|
12
|
+
def render?
|
13
|
+
@divider.present?
|
14
|
+
end
|
15
|
+
|
16
|
+
def invisible?
|
17
|
+
@divider.invisible
|
18
|
+
end
|
19
|
+
end
|
@@ -1,20 +1,11 @@
|
|
1
|
-
|
2
|
-
<div class="
|
3
|
-
|
4
|
-
|
5
|
-
|
1
|
+
<%= render Avo::CommonFieldWrapperComponent.new(field: @field, resource: @resource, index: @index, form: @form, displayed_in_modal: @displayed_in_modal, label: @label) do %>
|
2
|
+
<div class="self-center <% if @displayed_in_modal or @full_width %> w-full <% else %> w-full md:w-8/12 <% end %>" data-slot="value">
|
3
|
+
<%= content %>
|
4
|
+
<% if @model.present? and @model.errors.include? @field.id %>
|
5
|
+
<div class="text-red-600 mt-2 text-sm"><%= @model.errors.full_messages_for(@field.id).to_sentence %></div>
|
6
|
+
<% end %>
|
7
|
+
<% if @field.help %>
|
8
|
+
<div class="text-gray-600 mt-2 text-sm"><%== @field.help %></div>
|
9
|
+
<% end %>
|
6
10
|
</div>
|
7
|
-
|
8
|
-
<div class="px-6 py-3 self-center <% if @displayed_in_modal or @full_width %> w-full <% else %> w-8/12 <% end %>" data-slot="value">
|
9
|
-
<%= content %>
|
10
|
-
|
11
|
-
<% if @model.present? and @model.errors.include? @field.id %>
|
12
|
-
<div class="text-red-600 mt-2 text-sm"><%= @model.errors.full_messages_for(@field.id).to_sentence %></div>
|
13
|
-
<% end %>
|
14
|
-
|
15
|
-
<% if @field.help %>
|
16
|
-
<div class="text-gray-600 mt-2 text-sm"><%== @field.help %></div>
|
17
|
-
<% end %>
|
18
|
-
</div>
|
19
|
-
</div>
|
20
|
-
</div>
|
11
|
+
<% end %>
|
@@ -12,13 +12,5 @@ class Avo::Edit::FieldWrapperComponent < ViewComponent::Base
|
|
12
12
|
@model = resource.present? ? resource.model : nil
|
13
13
|
@full_width = full_width
|
14
14
|
@label = label
|
15
|
-
|
16
|
-
if (@index != 0) || @displayed_in_modal
|
17
|
-
@classes += " border-t"
|
18
|
-
end
|
19
|
-
end
|
20
|
-
|
21
|
-
def label
|
22
|
-
@label || @field.name
|
23
15
|
end
|
24
16
|
end
|
@@ -0,0 +1,12 @@
|
|
1
|
+
<% if @add_background %>
|
2
|
+
<div class="bg-white rounded shadow-panel">
|
3
|
+
<% end %>
|
4
|
+
<div class="relative flex-1 flex flex-col items-center justify-center space-y-12 py-24">
|
5
|
+
<%= helpers.svg view_type_svg, class: 'h-[250px]' %>
|
6
|
+
<div class="text-gray-500 text-center">
|
7
|
+
<%= message %>
|
8
|
+
</div>
|
9
|
+
</div>
|
10
|
+
<% if @add_background %>
|
11
|
+
</div>
|
12
|
+
<% end %>
|
@@ -0,0 +1,24 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
class Avo::EmptyStateComponent < ViewComponent::Base
|
4
|
+
def initialize(message: nil, resource_name: nil, related_name: nil, view_type: :table, add_background: false)
|
5
|
+
@message = message
|
6
|
+
@view_type = view_type
|
7
|
+
@related_name = related_name
|
8
|
+
@resource_name = resource_name
|
9
|
+
@add_background = add_background
|
10
|
+
end
|
11
|
+
|
12
|
+
def message
|
13
|
+
return @message if @message.present?
|
14
|
+
|
15
|
+
translation_tag = @related_name.present? ? 'avo.no_related_item_found' : 'avo.no_item_found'
|
16
|
+
helpers.t translation_tag, item: @resource_name
|
17
|
+
end
|
18
|
+
|
19
|
+
def view_type_svg
|
20
|
+
return "grid-empty-state" if @view_type.to_sym == :grid
|
21
|
+
|
22
|
+
"table-empty-state"
|
23
|
+
end
|
24
|
+
end
|
@@ -7,7 +7,8 @@
|
|
7
7
|
[type.to_s, resource.model_key]
|
8
8
|
end.to_h
|
9
9
|
%>
|
10
|
-
<div
|
10
|
+
<div class="divide-y"
|
11
|
+
data-controller="belongs-to-field"
|
11
12
|
data-searchable="<%= @field.searchable %>"
|
12
13
|
data-association="<%= @field.id %>"
|
13
14
|
data-association-class="<%= @field&.target_resource&.model_class || nil %>"
|
@@ -1,7 +1,7 @@
|
|
1
1
|
<%= edit_field_wrapper field: @field, index: @index, form: @form, resource: @resource, dash_if_blank: false, displayed_in_modal: @displayed_in_modal do %>
|
2
2
|
<div class="h-8 flex items-center">
|
3
3
|
<%= @form.check_box @field.id,
|
4
|
-
class: '
|
4
|
+
class: 'text-lg h-4 w-4',
|
5
5
|
disabled: @field.readonly,
|
6
6
|
checked: @field.value
|
7
7
|
%>
|
@@ -17,7 +17,7 @@
|
|
17
17
|
end
|
18
18
|
%>
|
19
19
|
<label class="block">
|
20
|
-
<%= check_box_tag "#{model_param_key}[#{@field.id}][]", id, checked, { class: "w-
|
20
|
+
<%= check_box_tag "#{model_param_key}[#{@field.id}][]", id, checked, { class: "w-4 h-4", disabled: @field.readonly, id: "#{model_param_key}_#{@field.id}_#{id}" } %> <%= label %>
|
21
21
|
</label>
|
22
22
|
<% end %>
|
23
23
|
</div>
|
@@ -1,12 +1,12 @@
|
|
1
1
|
<%
|
2
|
-
classes = 'h-
|
2
|
+
classes = 'h-6 float-left mr-1'
|
3
3
|
|
4
4
|
if @checked
|
5
|
-
classes += ' text-
|
6
|
-
icon = 'check-circle'
|
5
|
+
classes += ' text-green-600'
|
6
|
+
icon = 'heroicons/outline/check-circle'
|
7
7
|
else
|
8
8
|
classes += ' text-red-500'
|
9
|
-
icon = 'x-circle'
|
9
|
+
icon = 'heroicons/outline/x-circle'
|
10
10
|
end
|
11
11
|
%>
|
12
12
|
<%= helpers.svg "#{icon}.svg", class: classes %>
|
@@ -6,9 +6,9 @@
|
|
6
6
|
@options.each do |id, label|
|
7
7
|
checked = @value.present? && @value[id.to_s].present?
|
8
8
|
%>
|
9
|
-
<div>
|
9
|
+
<div class="flex flex-nowrap">
|
10
10
|
<%= render Avo::Fields::Common::BooleanCheckComponent.new checked: checked %>
|
11
|
-
<div class="ml-
|
11
|
+
<div class="ml-px text-left py-px"><%= label %></div>
|
12
12
|
</div>
|
13
13
|
<% end %>
|
14
14
|
</div>
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<div class="relative
|
1
|
+
<div class="relative py-3 grid xs:grid-cols-2 sm:grid-cols-2 xl:grid-cols-3 2xl:grid-cols-4 gap-3 rounded-xl">
|
2
2
|
<% @field.value.attachments.each do |file| %>
|
3
|
-
<%= render Avo::Fields::Common::
|
3
|
+
<%= render Avo::Fields::Common::SingleFileViewerComponent.new field: @field, resource: @resource, file: file %>
|
4
4
|
<% end %>
|
5
5
|
</div>
|
@@ -7,6 +7,6 @@
|
|
7
7
|
options[:size] = @size if @size.present?
|
8
8
|
query = options.map { |key, value| "#{key}=#{value}" }.join('&')
|
9
9
|
url = URI::HTTPS.build(host: "www.gravatar.com", path: "/avatar/#{@md5}", query: query)
|
10
|
-
classes = @rounded ? '
|
10
|
+
classes = @rounded ? 'rounded-full' : ''
|
11
11
|
%>
|
12
12
|
<%= link_to_if @link_to_resource.present?, image_tag(url.to_s, class: classes), @link, title: @title %>
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<div class="flex items-start py-1 leading-tight
|
2
|
-
<div class="
|
1
|
+
<div class="flex items-start py-1 leading-tight bg-gray-100 text-gray-500 text-xs">
|
2
|
+
<div class="py-2 px-6 h-full w-full">
|
3
3
|
<% if @value.present? %>
|
4
4
|
<% if @as_html %>
|
5
5
|
<%== @value %>
|
@@ -1,4 +1,4 @@
|
|
1
|
-
<div class="w-full shadow-lg rounded
|
1
|
+
<div class="w-full shadow-lg rounded overflow-hidden"
|
2
2
|
data-controller="key-value"
|
3
3
|
data-key-value-target="controller"
|
4
4
|
data-options="<%= @field.options.to_json %>"
|
@@ -7,7 +7,7 @@
|
|
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-
|
10
|
+
<div class="flex w-full bg-gray-700 shadow overflow-hidden">
|
11
11
|
<div class="w-1/2 py-3 px-3 uppercase font-semibold text-xs text-white border-gray-600 border-r">
|
12
12
|
<%= @field.key_label %>
|
13
13
|
</div>
|
@@ -1,33 +1,52 @@
|
|
1
|
-
<div class="relative min-h-full max-w-full flex-1 space-y-3">
|
2
|
-
<% if
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
1
|
+
<div class="relative min-h-full max-w-full flex-1 flex flex-col justify-between space-y-3">
|
2
|
+
<% if file.present? %>
|
3
|
+
<div class="flex flex-col justify-between h-full">
|
4
|
+
<% if file.representable? && is_image? %>
|
5
|
+
<div class="max-h-[42rem] h-full flex">
|
6
|
+
<%= image_tag helpers.main_app.url_for(file), class: 'rounded-lg object-cover' %>
|
7
|
+
</div>
|
8
|
+
<% elsif is_audio? %>
|
9
|
+
<%= audio_tag(helpers.main_app.url_for(file), controls: true, preload: false, class: 'w-full') %>
|
10
|
+
<% elsif is_video? %>
|
11
|
+
<%= video_tag(helpers.main_app.url_for(file), controls: true, preload: false, class: 'w-full') %>
|
12
|
+
<% else %>
|
13
|
+
<div class="relative flex flex-col justify-evenly items-center px-2 rounded-lg border bg-white border-gray-500 min-h-24">
|
14
|
+
<div class="flex flex-col justify-center items-center w-full">
|
15
|
+
<%= helpers.svg 'document-text', class: 'h-10 text-gray-600 mb-2' %>
|
13
16
|
</div>
|
14
17
|
</div>
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
<div class="flex
|
19
|
-
<div>
|
18
|
+
<% end %>
|
19
|
+
<span class="text-gray-500 mt-2 text-sm truncate" title="<%= file.filename %>"><%= file.filename %></span>
|
20
|
+
</div>
|
21
|
+
<div class="flex space-x-2">
|
22
|
+
<div class="flex">
|
20
23
|
<% if @resource.authorization.authorize_action(:download_attachments?, raise_exception: false) %>
|
21
|
-
<%= a_link helpers.main_app.url_for(
|
22
|
-
|
23
|
-
|
24
|
+
<%= a_link helpers.main_app.url_for(file),
|
25
|
+
icon: 'heroicons/outline/download',
|
26
|
+
color: :primary,
|
27
|
+
download: true,
|
28
|
+
class: 'text-center',
|
29
|
+
title: t('avo.download_file'),
|
30
|
+
data: { tippy: :tooltip },
|
31
|
+
compact: true,
|
32
|
+
size: :xs %>
|
24
33
|
<% end %>
|
25
34
|
</div>
|
26
35
|
<div>
|
27
36
|
<% if @resource.authorization.authorize_action(:delete_attachments?, raise_exception: false) %>
|
28
|
-
<%= a_link
|
29
|
-
|
30
|
-
|
37
|
+
<%= a_link destroy_path,
|
38
|
+
icon: 'heroicons/outline/trash',
|
39
|
+
method: :delete,
|
40
|
+
color: :red,
|
41
|
+
compact: true,
|
42
|
+
size: :xs,
|
43
|
+
class: 'text-center',
|
44
|
+
title: t('avo.delete_file', item: file.filename),
|
45
|
+
data: {
|
46
|
+
'turbo-frame': 'destroy_attachment_form',
|
47
|
+
confirm: t('avo.are_you_sure'),
|
48
|
+
tippy: :tooltip
|
49
|
+
} %>
|
31
50
|
<% end %>
|
32
51
|
</div>
|
33
52
|
</div>
|
@@ -3,13 +3,41 @@
|
|
3
3
|
class Avo::Fields::Common::SingleFileViewerComponent < ViewComponent::Base
|
4
4
|
include Avo::ApplicationHelper
|
5
5
|
|
6
|
-
def initialize(
|
7
|
-
@id = id
|
6
|
+
def initialize(file: nil, field:, resource:)
|
8
7
|
@file = file
|
9
|
-
@
|
10
|
-
@is_audio = is_audio
|
11
|
-
@direct_upload = direct_upload
|
12
|
-
@button_size = button_size
|
8
|
+
@field = field
|
13
9
|
@resource = resource
|
14
10
|
end
|
11
|
+
|
12
|
+
def destroy_path
|
13
|
+
"#{@resource.record_path}/active_storage_attachments/#{id}/#{file.id}"
|
14
|
+
end
|
15
|
+
|
16
|
+
def id
|
17
|
+
@field.id
|
18
|
+
end
|
19
|
+
|
20
|
+
def file
|
21
|
+
@file || @field.value.attachment
|
22
|
+
rescue
|
23
|
+
nil
|
24
|
+
end
|
25
|
+
|
26
|
+
def is_image?
|
27
|
+
file.image? || @field.is_image
|
28
|
+
rescue
|
29
|
+
false
|
30
|
+
end
|
31
|
+
|
32
|
+
def is_audio?
|
33
|
+
file.audio? || @field.is_audio
|
34
|
+
rescue
|
35
|
+
false
|
36
|
+
end
|
37
|
+
|
38
|
+
def is_video?
|
39
|
+
file.video? || @field.is_video
|
40
|
+
rescue
|
41
|
+
false
|
42
|
+
end
|
15
43
|
end
|