css-zero 0.0.60 → 0.0.62

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 871a8269f4d74512519b9582720a027fe3ef50162cc5391aa4c53874ecb496f2
4
- data.tar.gz: 0e42421a174fbda4a1d7246ebd46f36bb60425cb0e3e6943fc553e85ac9e3565
3
+ metadata.gz: 50f4f06305367205ea49ea3f51a52d15f1be0d03412988a1721c3d8fb21078f7
4
+ data.tar.gz: fc0907d77ef83b4c69446373baa99606a8217f406f4fb2ed78eaaeca0b738a3c
5
5
  SHA512:
6
- metadata.gz: 330c2aa8bf2cf91b9fad4fb573e52900789f93556f6cb5e6552e56311b0ab07e8f28c24ca95e626c25552213906705a1f45a9013a85dbd1cb30066e1a2004f6e
7
- data.tar.gz: 8501b13069a736a3f89f83634f841680daea78db53341a5e77d0deb417a352187633efeb294cadd4bf8f112cb2e2299e307a6ff1071facd09af5ab3af69c10eb
6
+ metadata.gz: aa156ba233ef386980a0ee10801205adeab2d75d4698a2828f164437db63caabb3f73fef9a1d0b08aaf6bbfa0cf4304d178180a692eead1f017a0725d73a28e6
7
+ data.tar.gz: ebad60a25af3c51dddaea41a62cce99aa1aca172bbde633a8b6852b0864097764ffea8ec57a62e0c49a6713e2edbe59d7ea38d7c141824d06ad70ee533217036
@@ -1,3 +1,3 @@
1
1
  module CssZero
2
- VERSION = "0.0.60"
2
+ VERSION = "0.0.62"
3
3
  end
@@ -2,7 +2,7 @@ Description:
2
2
  This will add components into your project.
3
3
 
4
4
  Components:
5
- accordion alert autosave avatar badge breadcrumb button card carousel chart check_all combobox command collapsible datepicker dialog dropdown flash form fullscreen hotkey input input_concerns inputmask layouts lightbox local_time pagination progress prose sheet skeleton switch table tabs trix upload_preview toggle web_share
5
+ accordion alert autosave avatar badge breadcrumb button card carousel chart check_all combobox command collapsible datepicker dialog dropdown flash form fullscreen hotkey input input_concerns inputmask layouts lightbox local_time navigation pagination progress prose sheet skeleton sortable switch table tabs tooltip trix upload_preview toggle web_share
6
6
 
7
7
  Example:
8
8
  bin/rails generate css_zero:add [components...]
@@ -87,6 +87,8 @@ lightbox:
87
87
  - app/assets/images/x.svg
88
88
  local_time:
89
89
  - app/javascript/controllers/local_time_controller.js
90
+ navigation:
91
+ - app/javascript/controllers/navigation_controller.js
90
92
  pagination:
91
93
  - app/assets/images/chevron-right.svg
92
94
  - app/assets/images/chevron-left.svg
@@ -104,6 +106,8 @@ sheet:
104
106
  - app/assets/images/x.svg
105
107
  skeleton:
106
108
  - app/assets/stylesheets/skeleton.css
109
+ sortable:
110
+ - app/javascript/controllers/sortable_controller.js
107
111
  switch:
108
112
  - app/assets/stylesheets/switch.css
109
113
  table:
@@ -111,6 +115,9 @@ table:
111
115
  tabs:
112
116
  - app/assets/stylesheets/tabs.css
113
117
  - app/javascript/controllers/tabs_controller.js
118
+ tooltip:
119
+ - app/assets/stylesheets/tooltip.css
120
+ - app/javascript/controllers/tooltip_controller.js
114
121
  trix:
115
122
  - app/assets/stylesheets/ztrix.css
116
123
  upload_preview:
@@ -0,0 +1,22 @@
1
+ .tippy-box {
2
+ background-color: var(--color-bg);
3
+ border: 1px solid var(--color-border);
4
+ border-radius: var(--rounded-md);
5
+ box-shadow: var(--shadow-md);
6
+ color: var(--color-text);
7
+ font-size: var(--text-sm);
8
+ line-height: var(--leading-normal);
9
+ transition-property: transform, visibility, opacity;
10
+
11
+ &[data-state=hidden] {
12
+ opacity: 0;
13
+ }
14
+
15
+ &[data-state=visible] {
16
+ transition-timing-function: var(--ease-in);
17
+ }
18
+
19
+ .tippy-content {
20
+ padding: var(--size-1_5) var(--size-3);
21
+ }
22
+ }
@@ -0,0 +1,16 @@
1
+ import { Controller } from "@hotwired/stimulus"
2
+ import { Turbo } from "@hotwired/turbo-rails"
3
+
4
+ export default class extends Controller {
5
+ back() {
6
+ history.back()
7
+ }
8
+
9
+ forward() {
10
+ history.forward()
11
+ }
12
+
13
+ reload() {
14
+ Turbo.visit(location.href, { action: "replace", shouldCacheSnapshot: false })
15
+ }
16
+ }
@@ -0,0 +1,23 @@
1
+ import { Controller } from "@hotwired/stimulus"
2
+ import { put } from "https://cdn.skypack.dev/@rails/request.js@0.0.11"
3
+ import Sortable from "https://cdn.skypack.dev/sortablejs"
4
+
5
+ export default class extends Controller {
6
+ static values = { url: String, group: String, handle: String }
7
+
8
+ connect() {
9
+ this.sortable = new Sortable(this.element, this.#options)
10
+ }
11
+
12
+ disconnect() {
13
+ this.sortable.destroy()
14
+ }
15
+
16
+ #submit({ item, newIndex, to }) {
17
+ put(item.dataset.urlValue, { responseKind: "plain", query: { position: newIndex, parent_id: to.dataset.parentId } })
18
+ }
19
+
20
+ get #options() {
21
+ return { animation: 150, onAdd: this.#submit, onUpdate: this.#submit, group: this.groupValue, handle: this.handleValue }
22
+ }
23
+ }
@@ -0,0 +1,14 @@
1
+ import { Controller } from "@hotwired/stimulus"
2
+ import tippy from "https://cdn.skypack.dev/tippy.js@6.3.7"
3
+
4
+ export default class extends Controller {
5
+ static values = { content: String }
6
+
7
+ connect() {
8
+ this.tooltip = tippy(this.element, { content: this.contentValue, arrow: false, interactive: true, delay: [700, 0], offset: [0, 3] })
9
+ }
10
+
11
+ disconnect() {
12
+ this.tooltip.destroy()
13
+ }
14
+ }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: css-zero
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.60
4
+ version: 0.0.62
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lázaro Nixon
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-11-08 00:00:00.000000000 Z
11
+ date: 2024-11-13 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description:
14
14
  email: lazaronixon@hotmail.com
@@ -82,6 +82,7 @@ files:
82
82
  - lib/generators/css_zero/add/templates/app/assets/stylesheets/tabs.css
83
83
  - lib/generators/css_zero/add/templates/app/assets/stylesheets/toggle.css
84
84
  - lib/generators/css_zero/add/templates/app/assets/stylesheets/tom-select.css
85
+ - lib/generators/css_zero/add/templates/app/assets/stylesheets/tooltip.css
85
86
  - lib/generators/css_zero/add/templates/app/assets/stylesheets/zcombobox.css
86
87
  - lib/generators/css_zero/add/templates/app/assets/stylesheets/zdatepicker.css
87
88
  - lib/generators/css_zero/add/templates/app/assets/stylesheets/ztrix.css
@@ -106,9 +107,12 @@ files:
106
107
  - lib/generators/css_zero/add/templates/app/javascript/controllers/list_controller.js
107
108
  - lib/generators/css_zero/add/templates/app/javascript/controllers/local_time_controller.js
108
109
  - lib/generators/css_zero/add/templates/app/javascript/controllers/menu_controller.js
110
+ - lib/generators/css_zero/add/templates/app/javascript/controllers/navigation_controller.js
109
111
  - lib/generators/css_zero/add/templates/app/javascript/controllers/popover_controller.js
110
112
  - lib/generators/css_zero/add/templates/app/javascript/controllers/revealable_input_controller.js
113
+ - lib/generators/css_zero/add/templates/app/javascript/controllers/sortable_controller.js
111
114
  - lib/generators/css_zero/add/templates/app/javascript/controllers/tabs_controller.js
115
+ - lib/generators/css_zero/add/templates/app/javascript/controllers/tooltip_controller.js
112
116
  - lib/generators/css_zero/add/templates/app/javascript/controllers/upload_preview_controller.js
113
117
  - lib/generators/css_zero/add/templates/app/javascript/controllers/web_share_controller.js
114
118
  - lib/generators/css_zero/authentication/authentication_generator.rb