@bildvitta/quasar-ui-asteroid 3.4.0 → 3.5.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. package/package.json +2 -2
  2. package/src/components/actions-menu/QasActionsMenu.vue +86 -37
  3. package/src/components/actions-menu/QasActionsMenu.yml +6 -6
  4. package/src/components/app-menu/QasAppMenu.vue +1 -1
  5. package/src/components/copy/QasCopy.vue +1 -1
  6. package/src/components/delete/QasDelete.vue +1 -1
  7. package/src/components/field/QasField.vue +14 -6
  8. package/src/components/filters/QasFilters.vue +6 -1
  9. package/src/components/filters/QasFilters.yml +6 -0
  10. package/src/components/form-generator/QasFormGenerator.yml +1 -1
  11. package/src/components/grid-generator/QasGridGenerator.yml +1 -1
  12. package/src/components/list-view/QasListView.vue +67 -8
  13. package/src/components/list-view/QasListView.yml +4 -0
  14. package/src/components/nested-fields/QasNestedFields.vue +101 -41
  15. package/src/components/nested-fields/QasNestedFields.yml +30 -10
  16. package/src/components/option-group/QasOptionGroup.vue +54 -0
  17. package/src/components/option-group/QasOptionGroup.yml +30 -0
  18. package/src/components/pagination/QasPagination.vue +27 -0
  19. package/src/components/pagination/QasPagination.yml +4 -0
  20. package/src/components/select/QasSelect.vue +15 -8
  21. package/src/components/select/QasSelect.yml +0 -4
  22. package/src/components/table-generator/QasTableGenerator.vue +10 -2
  23. package/src/components/table-generator/QasTableGenerator.yml +14 -0
  24. package/src/components/text-truncate/QasTextTruncate.vue +1 -1
  25. package/src/css/components/item.scss +4 -0
  26. package/src/css/plugins/index.scss +1 -0
  27. package/src/css/plugins/notify.scss +40 -0
  28. package/src/css/variables/button.scss +2 -2
  29. package/src/css/variables/spacing.scss +5 -5
  30. package/src/css/variables/typography.scss +24 -24
  31. package/src/helpers/set-scroll-on-grab.js +13 -4
  32. package/src/index.scss +4 -1
  33. package/src/mixins/generator.js +1 -1
  34. package/src/plugins/notify-error/NotifyError.js +7 -5
  35. package/src/plugins/notify-success/NotifySuccess.js +7 -5
  36. package/src/shared/notify-config.js +7 -0
  37. package/src/vue-plugin.js +6 -0
@@ -27,15 +27,15 @@ $space-md: (
27
27
  y: $space-y-base
28
28
  );
29
29
 
30
- // O tamanho original seria "16px * 1.5" ou "24px", alterado para ter "32px"
31
30
  $space-lg: (
32
- x: ($space-x-base * 2),
33
- y: ($space-y-base * 2)
31
+ x: ($space-x-base * 1.5),
32
+ y: ($space-y-base * 1.5)
34
33
  );
35
34
 
35
+ // O tamanho original seria "16px * 3" ou "48px", alterado para ter "32px"
36
36
  $space-xl: (
37
- x: ($space-x-base * 3),
38
- y: ($space-y-base * 3)
37
+ x: ($space-x-base * 2),
38
+ y: ($space-y-base * 2)
39
39
  );
40
40
 
41
41
  $spaces: (
@@ -9,48 +9,48 @@
9
9
 
10
10
  // headings
11
11
  $h1: (
12
- size: 6rem,
13
- line-height: 6rem,
12
+ size: 3rem,
13
+ line-height: 1.5rem,
14
14
  letter-spacing: 0,
15
15
  weight: 800,
16
16
  margin: 0
17
17
  );
18
18
 
19
19
  $h2: (
20
- size: 3.75rem,
21
- line-height: 3.75rem,
20
+ size: 2rem,
21
+ line-height: 1.5rem,
22
22
  letter-spacing: 0,
23
23
  weight: 700,
24
24
  margin: 0
25
25
  );
26
26
 
27
27
  $h3: (
28
- size: 3rem,
29
- line-height: 2.5rem,
28
+ size: 1.5rem,
29
+ line-height: 1.5rem,
30
30
  letter-spacing: 0,
31
- weight: 600,
31
+ weight: 700,
32
32
  margin: 0
33
33
  );
34
34
 
35
35
  $h4: (
36
- size: 2.125rem,
37
- line-height: 2.5rem,
36
+ size: 1.125rem,
37
+ line-height: 1.5rem,
38
38
  letter-spacing: 0,
39
- weight: 800,
39
+ weight: 600,
40
40
  margin: 0
41
41
  );
42
42
 
43
43
  $h5: (
44
- size: 1.5rem,
45
- line-height: 2rem,
44
+ size: 1rem,
45
+ line-height: 1.5rem,
46
46
  letter-spacing: 0,
47
- weight: 700,
47
+ weight: 600,
48
48
  margin: 0
49
49
  );
50
50
 
51
51
  $h6: (
52
- size: 1.25rem,
53
- line-height: 2rem,
52
+ size: 0.875rem,
53
+ line-height: 1.5rem,
54
54
  letter-spacing: 0,
55
55
  weight: 600,
56
56
  margin: 0
@@ -59,14 +59,14 @@ $h6: (
59
59
  // subtitles
60
60
  $subtitle1: (
61
61
  size: 1rem,
62
- line-height: 1.75rem,
62
+ line-height: 1.5rem,
63
63
  letter-spacing: 0,
64
- weight: 700
64
+ weight: 600
65
65
  );
66
66
 
67
67
  $subtitle2: (
68
68
  size: 0.875rem,
69
- line-height: 1.375rem,
69
+ line-height: 1.5rem,
70
70
  letter-spacing: 0,
71
71
  weight: 600
72
72
  );
@@ -76,20 +76,20 @@ $body1: (
76
76
  size: 1rem,
77
77
  line-height: 1.5rem,
78
78
  letter-spacing: 0,
79
- weight: 500
79
+ weight: 400
80
80
  );
81
81
 
82
82
  $body2: (
83
83
  size: 0.875rem,
84
- line-height: 1.25rem,
84
+ line-height: 1.5rem,
85
85
  letter-spacing: 0,
86
86
  weight: 400
87
87
  );
88
88
 
89
89
  // overline
90
90
  $overline: (
91
- size: 0.75rem,
92
- line-height: 2rem,
91
+ size: 0.875rem,
92
+ line-height: 1.5rem,
93
93
  letter-spacing: 0.25rem,
94
94
  weight: 600
95
95
  );
@@ -97,9 +97,9 @@ $overline: (
97
97
  // caption
98
98
  $caption: (
99
99
  size: 0.75rem,
100
- line-height: 1.25rem,
100
+ line-height: 1.5rem,
101
101
  letter-spacing: 0,
102
- weight: 700
102
+ weight: 600
103
103
  );
104
104
 
105
105
  $headings: (
@@ -2,6 +2,7 @@ export default function (element) {
2
2
  setStyle()
3
3
 
4
4
  let isDown = false
5
+ let moved = false
5
6
  let startX
6
7
  let scrollLeft
7
8
 
@@ -12,35 +13,38 @@ export default function (element) {
12
13
 
13
14
  function onMouseDown (event) {
14
15
  isDown = true
16
+ moved = false
17
+
15
18
  element.classList.add('active')
19
+
16
20
  startX = event.pageX - element.offsetLeft
17
21
  scrollLeft = element.scrollLeft
18
22
  }
19
23
 
20
24
  function onMouseLeave () {
21
25
  isDown = false
22
- element.classList.remove('active')
23
26
 
27
+ element.classList.remove('active')
24
28
  setStyle()
25
29
  }
26
30
 
27
31
  function onMouseUp () {
28
32
  isDown = false
29
- element.classList.remove('active')
30
33
 
34
+ element.classList.remove('active')
31
35
  setStyle()
32
36
  }
33
37
 
34
38
  function onMouseMove (event) {
39
+ if (event) event.preventDefault()
35
40
  if (!isDown) return
36
41
 
37
- event.preventDefault()
38
-
39
42
  setStyle('grabbing')
40
43
 
41
44
  const x = event.pageX - element.offsetLeft
42
45
  const walk = (x - startX) * 3 // scroll-fast
43
46
  element.scrollLeft = scrollLeft - walk
47
+ moved = true
44
48
  }
45
49
 
46
50
  function setStyle (model = 'grab') {
@@ -54,8 +58,13 @@ export default function (element) {
54
58
  element.removeEventListener('mousemove', onMouseMove)
55
59
  }
56
60
 
61
+ function haveMoved () {
62
+ return moved
63
+ }
64
+
57
65
  return {
58
66
  element,
67
+ haveMoved,
59
68
  destroyEvents
60
69
  }
61
70
  }
package/src/index.scss CHANGED
@@ -22,8 +22,11 @@ $generic-border-radius: var(--qas-generic-border-radius);
22
22
  // components
23
23
  @import './css/components/index';
24
24
 
25
+ // plugins
26
+ @import './css/plugins/index';
27
+
25
28
  // utils
26
29
  @import './css/utils/index';
27
30
 
28
31
  // mixins
29
- @import './css/mixins/index'
32
+ @import './css/mixins/index';
@@ -13,7 +13,7 @@ export default {
13
13
  },
14
14
 
15
15
  gutter: {
16
- default: 'md',
16
+ default: 'lg',
17
17
  type: [String, Boolean],
18
18
  validator: value => {
19
19
  return typeof value === 'boolean' || ['xs', 'sm', 'md', 'lg', 'xl'].includes(value)
@@ -1,10 +1,12 @@
1
1
  import { Notify } from 'quasar'
2
+ import notifyConfig from '../../shared/notify-config.js'
2
3
 
3
- Notify.registerType('error', {
4
- color: 'negative',
5
- progress: true
6
- })
4
+ Notify.registerType('error', { icon: 'o_cancel', ...notifyConfig })
7
5
 
8
6
  export default (message, caption) => {
9
- Notify.create({ caption, message, type: 'error' })
7
+ Notify.create({
8
+ caption,
9
+ message,
10
+ type: 'error'
11
+ })
10
12
  }
@@ -1,10 +1,12 @@
1
1
  import { Notify } from 'quasar'
2
+ import notifyConfig from '../../shared/notify-config.js'
2
3
 
3
- Notify.registerType('success', {
4
- icon: 'o_check',
5
- progress: true
6
- })
4
+ Notify.registerType('success', { icon: 'o_check_circle', ...notifyConfig })
7
5
 
8
6
  export default (message, caption) => {
9
- Notify?.create({ caption, message, type: 'success' })
7
+ Notify.create({
8
+ caption,
9
+ message,
10
+ type: 'success'
11
+ })
10
12
  }
@@ -0,0 +1,7 @@
1
+ export default {
2
+ color: 'grey-9',
3
+ progress: true,
4
+ closeBtn: 'x',
5
+ position: 'top',
6
+ timeout: 4000
7
+ }
package/src/vue-plugin.js CHANGED
@@ -29,7 +29,9 @@ import QasListView from './components/list-view/QasListView.vue'
29
29
  import QasMap from './components/map/QasMap.vue'
30
30
  import QasNestedFields from './components/nested-fields/QasNestedFields.vue'
31
31
  import QasNumericInput from './components/numeric-input/QasNumericInput.vue'
32
+ import QasOptionGroup from './components/option-group/QasOptionGroup.vue'
32
33
  import QasPageHeader from './components/page-header/QasPageHeader.vue'
34
+ import QasPagination from './components/pagination/QasPagination.vue'
33
35
  import QasPasswordInput from './components/password-input/QasPasswordInput.vue'
34
36
  import QasPasswordStrengthChecker from './components/password-strength-checker/QasPasswordStrengthChecker.vue'
35
37
  import QasProfile from './components/profile/QasProfile.vue'
@@ -99,7 +101,9 @@ function install (app) {
99
101
  app.component('QasMap', QasMap)
100
102
  app.component('QasNestedFields', QasNestedFields)
101
103
  app.component('QasNumericInput', QasNumericInput)
104
+ app.component('QasOptionGroup', QasOptionGroup)
102
105
  app.component('QasPageHeader', QasPageHeader)
106
+ app.component('QasPagination', QasPagination)
103
107
  app.component('QasPasswordInput', QasPasswordInput)
104
108
  app.component('QasPasswordStrengthChecker', QasPasswordStrengthChecker)
105
109
  app.component('QasProfile', QasProfile)
@@ -170,7 +174,9 @@ export {
170
174
  QasMap,
171
175
  QasNestedFields,
172
176
  QasNumericInput,
177
+ QasOptionGroup,
173
178
  QasPageHeader,
179
+ QasPagination,
174
180
  QasPasswordInput,
175
181
  QasPasswordStrengthChecker,
176
182
  QasProfile,