@bildvitta/quasar-ui-asteroid 3.20.0-beta.2 → 3.20.0-beta.21
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.
- package/package.json +3 -3
- package/src/asteroid.js +8 -1
- package/src/components/actions/QasActions.vue +12 -2
- package/src/components/actions-menu/QasActionsMenu.vue +18 -5
- package/src/components/alert/QasAlert.vue +89 -64
- package/src/components/app-user/QasAppUser.vue +2 -1
- package/src/components/board-generator/QasBoardGenerator.vue +883 -162
- package/src/components/board-generator/QasBoardGenerator.yml +83 -2
- package/src/components/board-generator/private/PvBoardGeneratorCardsContainer.vue +25 -0
- package/src/components/box/QasBox.vue +16 -3
- package/src/components/box/QasBox.yml +10 -0
- package/src/components/btn/QasBtn.vue +27 -5
- package/src/components/btn/QasBtn.yml +10 -1
- package/src/components/btn-dropdown/QasBtnDropdown.vue +13 -1
- package/src/components/card/QasCard.vue +97 -25
- package/src/components/card/QasCard.yml +10 -0
- package/src/components/card-image/QasCardImage.vue +10 -1
- package/src/components/card-image/QasCardImage.yml +5 -0
- package/src/components/chart-view/QasChartView.vue +4 -3
- package/src/components/chart-view/QasChartView.yml +5 -0
- package/src/components/checkbox/node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709/results.json +1 -0
- package/src/components/copy/QasCopy.vue +6 -1
- package/src/components/copy/QasCopy.yml +5 -0
- package/src/components/date-time-input/QasDateTimeInput.vue +30 -6
- package/src/components/dialog/QasDialog.vue +308 -91
- package/src/components/dialog/QasDialog.yml +51 -23
- package/src/components/dialog/composables/use-cancel.js +1 -1
- package/src/components/dialog/composables/use-dynamic-components.js +2 -2
- package/src/components/dialog/composables/use-ok.js +1 -0
- package/src/components/dialog-router/QasDialogRouter.vue +1 -1
- package/src/components/drawer/QasDrawer.vue +76 -26
- package/src/components/drawer/QasDrawer.yml +10 -0
- package/src/components/expansion-item/QasExpansionItem.yml +5 -0
- package/src/components/filters/QasFilters.vue +2 -1
- package/src/components/filters/private/PvFiltersActions.vue +79 -13
- package/src/components/form-generator/QasFormGenerator.vue +8 -1
- package/src/components/form-generator/QasFormGenerator.yml +10 -0
- package/src/components/form-view/QasFormView.vue +20 -11
- package/src/components/form-view/QasFormView.yml +6 -0
- package/src/components/gallery/composables/use-delete.js +2 -3
- package/src/components/gallery/private/PvGalleryCarouselDialog.vue +8 -7
- package/src/components/grid-item/node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709/results.json +1 -0
- package/src/components/header/QasHeader.vue +66 -11
- package/src/components/header/QasHeader.yml +16 -1
- package/src/components/infinite-scroll/QasInfiniteScroll.vue +1 -1
- package/src/components/label/QasLabel.vue +3 -1
- package/src/components/layout/QasLayout.vue +16 -1
- package/src/components/layout/private/PvLayoutNotificationsDrawer.vue +2 -1
- package/src/components/layout/private/PvLayoutOverlayDrawer.vue +4 -2
- package/src/components/lazy-loading-components/QasLazyLoadingComponents.vue +262 -0
- package/src/components/lazy-loading-components/QasLazyLoadingComponents.yml +49 -0
- package/src/components/list-view/QasListView.vue +12 -4
- package/src/components/list-view/QasListView.yml +12 -0
- package/src/components/page-header/QasPageHeader.vue +49 -3
- package/src/components/page-header/QasPageHeader.yml +5 -0
- package/src/components/router-link/QasRouterLink.vue +72 -0
- package/src/components/router-link/QasRouterLink.yml +24 -0
- package/src/components/search-box/QasSearchBox.vue +1 -1
- package/src/components/select/QasSelect.vue +8 -1
- package/src/components/select-list-dialog/QasSelectListDialog.vue +40 -20
- package/src/components/select-list-dialog/QasSelectListDialog.yml +14 -2
- package/src/components/signature-uploader/QasSignatureUploader.vue +5 -18
- package/src/components/single-view/QasSingleView.vue +2 -2
- package/src/components/skeleton/QasSkeleton.vue +139 -0
- package/src/components/skeleton/QasSkeleton.yml +48 -0
- package/src/components/sortable/QasSortable.vue +1 -1
- package/src/components/stepper/QasStepper.vue +24 -2
- package/src/components/table-generator/QasTableGenerator.vue +186 -35
- package/src/components/table-generator/QasTableGenerator.yml +6 -1
- package/src/components/tabs-generator/QasTabsGenerator.vue +14 -3
- package/src/components/tabs-generator/QasTabsGenerator.yml +5 -1
- package/src/components/text-truncate/QasTextTruncate.vue +61 -12
- package/src/components/text-truncate/QasTextTruncate.yml +5 -0
- package/src/components/toggle-visibility/QasToggleVisibility.vue +2 -1
- package/src/components/tooltip/QasTooltip.vue +6 -1
- package/src/components/tree-generator/QasTreeGenerator.vue +4 -6
- package/src/components/uploader/QasUploader.vue +12 -2
- package/src/composables/private/use-view.js +1 -1
- package/src/composables/use-overlay-navigation.js +116 -10
- package/src/composables/use-screen.js +17 -1
- package/src/css/components/button.scss +82 -3
- package/src/css/components/item.scss +6 -0
- package/src/css/utils/background.scss +5 -0
- package/src/css/utils/border.scss +6 -0
- package/src/css/utils/container.scss +4 -3
- package/src/css/utils/text.scss +9 -0
- package/src/helpers/copy-to-clipboard.js +2 -1
- package/src/helpers/filters.js +1 -1
- package/src/helpers/promise-handler.js +2 -1
- package/src/helpers/set-scroll-gradient.js +31 -8
- package/src/helpers/set-scroll-on-grab.js +10 -3
- package/src/index.scss +1 -0
- package/src/mixins/search-filter.js +7 -1
- package/src/plugins/delete/Delete.js +7 -9
- package/src/plugins/delete/Delete.yml +1 -1
- package/src/plugins/dialog/Dialog.yml +1 -1
- package/src/plugins/notify-error/NotifyError.yml +1 -1
- package/src/plugins/notify-success/NotifySuccess.yml +1 -1
- package/src/plugins/screen/Screen.js +17 -1
- package/src/plugins/screen/Screen.yml +5 -1
- package/src/vue-plugin.js +5 -7
- package/src/plugins/index.js +0 -5
|
@@ -186,9 +186,9 @@ export default {
|
|
|
186
186
|
|
|
187
187
|
destroyDialogConfig () {
|
|
188
188
|
return {
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
189
|
+
title: 'Excluir',
|
|
190
|
+
description: 'Todas as informações serão perdidas. Deseja realmente continuar?',
|
|
191
|
+
size: 'md',
|
|
192
192
|
ok: {
|
|
193
193
|
label: 'Excluir',
|
|
194
194
|
onClick: this.destroy
|
|
@@ -201,9 +201,7 @@ export default {
|
|
|
201
201
|
|
|
202
202
|
formDialogConfig () {
|
|
203
203
|
return {
|
|
204
|
-
|
|
205
|
-
title: this.isAdd ? 'Adicionar ramo' : 'Editar ramo'
|
|
206
|
-
},
|
|
204
|
+
title: this.isAdd ? 'Adicionar ramo' : 'Editar ramo',
|
|
207
205
|
ok: {
|
|
208
206
|
label: 'Salvar',
|
|
209
207
|
loading: this.isSubmitting
|
|
@@ -52,7 +52,7 @@ import { getImageSize, getResizeDimensions } from '../../helpers/images.js'
|
|
|
52
52
|
import { constructObject } from '../../helpers'
|
|
53
53
|
|
|
54
54
|
import { uid, extend } from 'quasar'
|
|
55
|
-
import
|
|
55
|
+
import NotifyError from '../../plugins/notify-error/NotifyError.js'
|
|
56
56
|
|
|
57
57
|
import Pica from 'pica'
|
|
58
58
|
|
|
@@ -317,7 +317,17 @@ export default {
|
|
|
317
317
|
} = this.$props
|
|
318
318
|
|
|
319
319
|
return {
|
|
320
|
-
dialogProps
|
|
320
|
+
dialogProps: {
|
|
321
|
+
title: 'Editar arquivo',
|
|
322
|
+
|
|
323
|
+
ok: {
|
|
324
|
+
label: 'Salvar',
|
|
325
|
+
...dialogProps.ok
|
|
326
|
+
},
|
|
327
|
+
|
|
328
|
+
...dialogProps
|
|
329
|
+
},
|
|
330
|
+
|
|
321
331
|
fields,
|
|
322
332
|
formGeneratorProps,
|
|
323
333
|
galleryCardProps,
|
|
@@ -17,22 +17,62 @@ const historyRoute = ref({
|
|
|
17
17
|
const canLeaveOverlay = ref(true)
|
|
18
18
|
|
|
19
19
|
/**
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
20
|
+
* Cria o estado de callbacks para uma entidade (ou para o modo padrão sem entidade).
|
|
21
|
+
*
|
|
22
|
+
* Definição de callbacks para a entidade.
|
|
23
|
+
* Obs: são arrays para permitir múltiplos callbacks, ex se você usa "onCloseOverlay" em 2 componentes
|
|
24
|
+
* diferentes da mesma entidade, ambos serão executados.
|
|
25
|
+
* @private
|
|
23
26
|
*/
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
27
|
+
function createCallbackFunctionsByEntity () {
|
|
28
|
+
return {
|
|
29
|
+
onCloseOverlay: [],
|
|
30
|
+
onExpandOverlay: [],
|
|
31
|
+
onHideOverlay: [],
|
|
32
|
+
onBackgroundChange: [],
|
|
33
|
+
onOverlayChange: []
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Registro de callbacks por entidade.
|
|
39
|
+
* A chave 'default' representa o modo padrão (sem entidade).
|
|
40
|
+
* @type {Map<string, ReturnType<typeof createCallbackFunctionsByEntity>>}
|
|
41
|
+
*/
|
|
42
|
+
const callbackFunctionsByEntity = new Map()
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* Retorna (ou cria) o estado compartilhado para a entidade informada.
|
|
46
|
+
* @private
|
|
47
|
+
* @param {string|undefined} entity
|
|
48
|
+
*/
|
|
49
|
+
function getCallbackFunctionsByEntity (entity) {
|
|
50
|
+
const entityKey = entity ?? 'default'
|
|
51
|
+
|
|
52
|
+
if (!callbackFunctionsByEntity.has(entityKey)) {
|
|
53
|
+
callbackFunctionsByEntity.set(entityKey, createCallbackFunctionsByEntity())
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
return callbackFunctionsByEntity.get(entityKey)
|
|
30
57
|
}
|
|
31
58
|
|
|
32
59
|
/**
|
|
33
60
|
* Composable para gerenciar navegação em overlays, sempre que for lidar com overlays utilize esse composable.
|
|
61
|
+
*
|
|
62
|
+
* @example
|
|
63
|
+
* Modo padrão — comportamento legado, estado global compartilhado
|
|
64
|
+
* const nav = useOverlayNavigation()
|
|
65
|
+
*
|
|
66
|
+
* Modo com entidade — página A e componente B compartilham 'activities', isolado de 'funnels'
|
|
67
|
+
* const nav = useOverlayNavigation('activities')
|
|
68
|
+
*
|
|
69
|
+
* @param {string} [entity] - Nome da entidade para isolar os callbacks.
|
|
70
|
+
* Quando informado, instâncias com a mesma entidade compartilham os callbacks entre si, mas são isoladas de
|
|
71
|
+
* instâncias com entidades diferentes.
|
|
34
72
|
*/
|
|
35
|
-
export default function useOverlayNavigation () {
|
|
73
|
+
export default function useOverlayNavigation (entity) {
|
|
74
|
+
const callbackFunctions = getCallbackFunctionsByEntity(entity)
|
|
75
|
+
|
|
36
76
|
// composables
|
|
37
77
|
const route = useRoute()
|
|
38
78
|
const router = useRouter()
|
|
@@ -255,6 +295,71 @@ export default function useOverlayNavigation () {
|
|
|
255
295
|
callbackFunctions[callbackName].forEach(fn => fn(payload))
|
|
256
296
|
}
|
|
257
297
|
|
|
298
|
+
/**
|
|
299
|
+
* Remove listeners registrados no composable.
|
|
300
|
+
*
|
|
301
|
+
* @param {Function|Function[]|string} [target] - Função, array de funções, nome da entidade ou vazio para limpar
|
|
302
|
+
* a entidade `default`.
|
|
303
|
+
*
|
|
304
|
+
* @example
|
|
305
|
+
* ```js
|
|
306
|
+
* const { onCloseOverlay, removeListeners } = useOverlayNavigation('activities')
|
|
307
|
+
*
|
|
308
|
+
* function handleClose () { ... }
|
|
309
|
+
* onCloseOverlay(handleClose)
|
|
310
|
+
*
|
|
311
|
+
* removeListeners(handleClose) - Remove apenas handleClose da entidade atual
|
|
312
|
+
*
|
|
313
|
+
* removeListeners([handleClose, handleExpand]) - Remove handleClose e handleExpand da entidade atual
|
|
314
|
+
*
|
|
315
|
+
* removeListeners('activities') - Remove todas as funções registradas na entidade 'activities'
|
|
316
|
+
*
|
|
317
|
+
* removeListeners() - Remove todas as funções das instâncias sem entidade (entity 'default')
|
|
318
|
+
* ```
|
|
319
|
+
*/
|
|
320
|
+
function removeListeners (target) {
|
|
321
|
+
// remove todos os callbacks da entidade 'default' (modo padrão sem entidade)
|
|
322
|
+
if (!target) {
|
|
323
|
+
const defaultCallbackFunctions = callbackFunctionsByEntity.get('default')
|
|
324
|
+
|
|
325
|
+
if (!defaultCallbackFunctions) return
|
|
326
|
+
|
|
327
|
+
for (const functionKey of Object.keys(defaultCallbackFunctions)) {
|
|
328
|
+
defaultCallbackFunctions[functionKey] = []
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
return
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
// Remove todos os callbacks de uma entidade pelo nome
|
|
335
|
+
if (typeof target === 'string') {
|
|
336
|
+
// Pego o estado da entidade informada.
|
|
337
|
+
const callbackFunctions = callbackFunctionsByEntity.get(target)
|
|
338
|
+
|
|
339
|
+
if (!callbackFunctions) return
|
|
340
|
+
|
|
341
|
+
// Reseto as funções de callback para a entidade, mantendo a estrutura mas limpando os arrays.
|
|
342
|
+
for (const functionKey of Object.keys(callbackFunctions)) {
|
|
343
|
+
callbackFunctions[functionKey] = []
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
return
|
|
347
|
+
}
|
|
348
|
+
|
|
349
|
+
// Normaliza para array e remove as funções da entidade atual
|
|
350
|
+
const functionsToRemove = Array.isArray(target) ? target : [target]
|
|
351
|
+
|
|
352
|
+
const callbackFunctionsKeys = Object.keys(callbackFunctions)
|
|
353
|
+
|
|
354
|
+
/**
|
|
355
|
+
* Percorro cada função de callback registrada na entidade atual e filtro as funções que devem ser removidas,
|
|
356
|
+
* mantendo as que não devem ser removidas.
|
|
357
|
+
*/
|
|
358
|
+
for (const key of callbackFunctionsKeys) {
|
|
359
|
+
callbackFunctions[key] = callbackFunctions[key].filter(fn => !functionsToRemove.includes(fn))
|
|
360
|
+
}
|
|
361
|
+
}
|
|
362
|
+
|
|
258
363
|
/**
|
|
259
364
|
* Função para disparar mudanças no background componente.
|
|
260
365
|
*
|
|
@@ -404,6 +509,7 @@ export default function useOverlayNavigation () {
|
|
|
404
509
|
triggerOverlayChange,
|
|
405
510
|
getNormalizedRoute,
|
|
406
511
|
toggleCanLeaveOverlay,
|
|
512
|
+
removeListeners,
|
|
407
513
|
|
|
408
514
|
// callbacks functions
|
|
409
515
|
onBackgroundChange,
|
|
@@ -7,8 +7,12 @@ import { computed, reactive } from 'vue'
|
|
|
7
7
|
* isSmall: boolean,
|
|
8
8
|
* isMedium: boolean,
|
|
9
9
|
* isLarge: boolean,
|
|
10
|
+
* isXLarge: boolean,
|
|
11
|
+
* is2XLarge: boolean,
|
|
10
12
|
* untilMedium: boolean,
|
|
11
13
|
* untilLarge: boolean,
|
|
14
|
+
* untilXLarge: boolean,
|
|
15
|
+
* until2XLarge: boolean,
|
|
12
16
|
* isMobile: boolean
|
|
13
17
|
* }}
|
|
14
18
|
*
|
|
@@ -25,15 +29,27 @@ export default function () {
|
|
|
25
29
|
// de 600 até 1023px
|
|
26
30
|
isMedium: computed(() => Screen.sm),
|
|
27
31
|
|
|
28
|
-
//
|
|
32
|
+
// Maior que 1023px
|
|
29
33
|
isLarge: computed(() => Screen.gt.sm),
|
|
30
34
|
|
|
35
|
+
// Maior que 1439px
|
|
36
|
+
isXLarge: computed(() => Screen.gt.md),
|
|
37
|
+
|
|
38
|
+
// Maior que 1919px
|
|
39
|
+
is2XLarge: computed(() => Screen.gt.lg),
|
|
40
|
+
|
|
31
41
|
// de 0 até 599px
|
|
32
42
|
untilMedium: computed(() => Screen.lt.sm),
|
|
33
43
|
|
|
34
44
|
// de 0 ate 1023px
|
|
35
45
|
untilLarge: computed(() => Screen.lt.md),
|
|
36
46
|
|
|
47
|
+
// de 0 até 1439px
|
|
48
|
+
untilXLarge: computed(() => Screen.lt.lg),
|
|
49
|
+
|
|
50
|
+
// de 0 até 1919px
|
|
51
|
+
until2XLarge: computed(() => Screen.lt.xl),
|
|
52
|
+
|
|
37
53
|
// Plataforma
|
|
38
54
|
isMobile: computed(() => Platform.is.mobile || false)
|
|
39
55
|
})
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
padding: var(--qas-spacing-xs) var(--qas-spacing-md) !important;
|
|
15
15
|
|
|
16
16
|
.q-icon {
|
|
17
|
-
font-size:
|
|
17
|
+
font-size: 18px !important;
|
|
18
18
|
}
|
|
19
19
|
|
|
20
20
|
&.qas-btn--icon-only.qas-btn--primary,
|
|
@@ -24,8 +24,8 @@
|
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
&.qas-btn--icon-only.qas-btn--tertiary {
|
|
27
|
-
height:
|
|
28
|
-
width:
|
|
27
|
+
height: 18px !important;
|
|
28
|
+
width: 18px !important;
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
31
|
|
|
@@ -226,4 +226,83 @@
|
|
|
226
226
|
.q-focus-helper {
|
|
227
227
|
display: none;
|
|
228
228
|
}
|
|
229
|
+
|
|
230
|
+
// Magic AI
|
|
231
|
+
&--magic-ai {
|
|
232
|
+
// CSS não suporta transição direta de gradient → cor sólida em background/background-clip.
|
|
233
|
+
// Para secondary/tertiary: transitamos -webkit-text-fill-color de transparent → cor sólida,
|
|
234
|
+
// deixando o gradient visível por baixo e criando um efeito de cross-fade.
|
|
235
|
+
&#{$root}--primary:not(:disabled) {
|
|
236
|
+
background: var(--qas-magic-ai-gradient);
|
|
237
|
+
background-size: 100%;
|
|
238
|
+
transition: background-size var(--qas-generic-transition);
|
|
239
|
+
|
|
240
|
+
&:hover {
|
|
241
|
+
background-size: 200%;
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
&#{$root}--secondary:not(:disabled) {
|
|
247
|
+
transition: color var(--qas-generic-transition);
|
|
248
|
+
|
|
249
|
+
.q-icon,
|
|
250
|
+
.qas-btn__label {
|
|
251
|
+
background: var(--qas-magic-ai-gradient) !important;
|
|
252
|
+
background-clip: text !important;
|
|
253
|
+
-webkit-background-clip: text;
|
|
254
|
+
-webkit-text-fill-color: transparent;
|
|
255
|
+
border: none !important;
|
|
256
|
+
transition: -webkit-text-fill-color var(--qas-generic-transition);
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
&::after {
|
|
260
|
+
background: var(--qas-magic-ai-gradient);
|
|
261
|
+
border-radius: inherit;
|
|
262
|
+
content: '';
|
|
263
|
+
inset: 0;
|
|
264
|
+
mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
|
|
265
|
+
mask-composite: exclude;
|
|
266
|
+
-webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
|
|
267
|
+
-webkit-mask-composite: xor;
|
|
268
|
+
padding: 0;
|
|
269
|
+
pointer-events: none;
|
|
270
|
+
position: absolute;
|
|
271
|
+
transition: opacity var(--qas-generic-transition);
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
&:hover {
|
|
275
|
+
color: $deep-purple-6 !important;
|
|
276
|
+
|
|
277
|
+
.q-icon,
|
|
278
|
+
.qas-btn__label {
|
|
279
|
+
color: $deep-purple-6 !important;
|
|
280
|
+
-webkit-text-fill-color: $deep-purple-6 !important;
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
&::after {
|
|
284
|
+
opacity: 0;
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
&#{$root}--tertiary:not(:disabled) {
|
|
290
|
+
.q-icon,
|
|
291
|
+
.qas-btn__label {
|
|
292
|
+
background: var(--qas-magic-ai-gradient);
|
|
293
|
+
background-clip: text;
|
|
294
|
+
-webkit-background-clip: text;
|
|
295
|
+
-webkit-text-fill-color: transparent;
|
|
296
|
+
transition: -webkit-text-fill-color var(--qas-generic-transition);
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
&:hover {
|
|
300
|
+
.q-icon,
|
|
301
|
+
.qas-btn__label {
|
|
302
|
+
color: $deep-purple-6 !important;
|
|
303
|
+
-webkit-text-fill-color: $deep-purple-6 !important;
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
}
|
|
229
308
|
}
|
|
@@ -54,6 +54,12 @@
|
|
|
54
54
|
display: none;
|
|
55
55
|
}
|
|
56
56
|
|
|
57
|
+
&:not(.disabled):hover .text-magic-ai {
|
|
58
|
+
background: none !important;
|
|
59
|
+
color: $deep-purple-6 !important;
|
|
60
|
+
-webkit-text-fill-color: $deep-purple-6 !important;
|
|
61
|
+
}
|
|
62
|
+
|
|
57
63
|
&__section--side {
|
|
58
64
|
padding-right: var(--qas-spacing-sm);
|
|
59
65
|
}
|
|
@@ -19,6 +19,12 @@
|
|
|
19
19
|
@include set-border-color(secondary-contrast, $secondary-contrast);
|
|
20
20
|
@include set-border-color('grey', $border-grey);
|
|
21
21
|
|
|
22
|
+
.border-magic-ai {
|
|
23
|
+
border-style: solid !important;
|
|
24
|
+
border-width: 1px !important;
|
|
25
|
+
border-image: var(--qas-magic-ai-gradient) 1 !important;
|
|
26
|
+
}
|
|
27
|
+
|
|
22
28
|
// Direction
|
|
23
29
|
.border-top {
|
|
24
30
|
border-top-width: 1px !important;
|
|
@@ -36,9 +36,10 @@
|
|
|
36
36
|
}
|
|
37
37
|
|
|
38
38
|
/**
|
|
39
|
-
* Adiciona padding no container para evitar que o botão do Gleap
|
|
40
|
-
*
|
|
39
|
+
* - Adiciona padding no ultimo container da pagina e no ultimo elemento do overlay para evitar que o botão do Gleap
|
|
40
|
+
* fique sobreposto ao conteúdo da página.
|
|
41
41
|
*/
|
|
42
|
-
body:has(.bb-feedback-button) .container
|
|
42
|
+
body:has(.bb-feedback-button) .q-page > .container:last-child,
|
|
43
|
+
body:has(.bb-feedback-button) .pv-layout-overlay-drawer__content > :last-child {
|
|
43
44
|
padding-bottom: 80px;
|
|
44
45
|
}
|
package/src/css/utils/text.scss
CHANGED
|
@@ -13,3 +13,12 @@
|
|
|
13
13
|
.text-no-decoration {
|
|
14
14
|
text-decoration: none !important;
|
|
15
15
|
}
|
|
16
|
+
|
|
17
|
+
// Colors
|
|
18
|
+
.text-magic-ai {
|
|
19
|
+
background: var(--qas-magic-ai-gradient);
|
|
20
|
+
background-clip: text;
|
|
21
|
+
-webkit-background-clip: text;
|
|
22
|
+
-webkit-text-fill-color: transparent;
|
|
23
|
+
color: transparent;
|
|
24
|
+
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { copyToClipboard } from 'quasar'
|
|
2
|
-
import
|
|
2
|
+
import NotifySuccess from '../plugins/notify-success/NotifySuccess.js'
|
|
3
|
+
import NotifyError from '../plugins/notify-error/NotifyError.js'
|
|
3
4
|
|
|
4
5
|
export default async (text, onLoading = () => {}) => {
|
|
5
6
|
onLoading(true)
|
package/src/helpers/filters.js
CHANGED
|
@@ -160,7 +160,7 @@ function parseValue (value) {
|
|
|
160
160
|
try { return JSON.parse(value) } catch { return value }
|
|
161
161
|
}
|
|
162
162
|
|
|
163
|
-
function booleanLabel (value, trueLabel = '
|
|
163
|
+
function booleanLabel (value, trueLabel = 'Sim', falseLabel = 'Não') {
|
|
164
164
|
try { return JSON.parse(value) ? trueLabel : falseLabel } catch { return value }
|
|
165
165
|
}
|
|
166
166
|
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Loading } from 'quasar'
|
|
2
|
-
import
|
|
2
|
+
import NotifySuccess from '../plugins/notify-success/NotifySuccess.js'
|
|
3
|
+
import NotifyError from '../plugins/notify-error/NotifyError.js'
|
|
3
4
|
|
|
4
5
|
/** Função para lidar com promises, por exemplo requests.
|
|
5
6
|
*
|
|
@@ -5,6 +5,18 @@ import { convertToRgb } from './colors'
|
|
|
5
5
|
* @typedef {'start'|'end'} Direction
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
+
/**
|
|
9
|
+
* Níveis de opacidade do gradiente.
|
|
10
|
+
* Nível 1: mais suave
|
|
11
|
+
* Nível 2: médio
|
|
12
|
+
* Nível 3: mais forte (padrão)
|
|
13
|
+
*/
|
|
14
|
+
const GRADIENT_LEVELS = {
|
|
15
|
+
1: { mid: 0.3, end: 0.5 },
|
|
16
|
+
2: { mid: 0.6, end: 0.8 },
|
|
17
|
+
3: { mid: 0.9, end: 1 }
|
|
18
|
+
}
|
|
19
|
+
|
|
8
20
|
/**
|
|
9
21
|
* Helper para adicionar um gradiente de scroll em um elemento.
|
|
10
22
|
*
|
|
@@ -12,17 +24,21 @@ import { convertToRgb } from './colors'
|
|
|
12
24
|
* @param {object} config.styles
|
|
13
25
|
* @param {string} config.styles.color - precisa ser uma cor RGB|HEX|RGBA
|
|
14
26
|
* @param {string} config.styles.size - tamanho do gradient (mudar somente quando for necessário)
|
|
27
|
+
* @param {1|2|3} config.styles.gradientLevel - nível de intensidade do gradiente (1: suave, 2: médio, 3: forte). Default: 3
|
|
15
28
|
* @param {'y'|'x'} config.orientation - direção do scroll (vertical ou horizontal)
|
|
16
29
|
*/
|
|
17
30
|
export default function setScrollGradient (config = {}) {
|
|
18
31
|
const { styles, orientation = 'y' } = config
|
|
19
|
-
const { color = '#FFFFFF', size = '40px' } = styles || {}
|
|
32
|
+
const { color = '#FFFFFF', size = '40px', gradientLevel = 3 } = styles || {}
|
|
20
33
|
|
|
21
34
|
const { r, g, b } = convertToRgb(color) || {}
|
|
22
35
|
const rgbParam = `${r}, ${g}, ${b}`
|
|
23
36
|
|
|
24
37
|
const isVertical = orientation === 'y'
|
|
25
38
|
|
|
39
|
+
// obtém os valores de opacidade baseado no nível
|
|
40
|
+
const level = GRADIENT_LEVELS[gradientLevel] || GRADIENT_LEVELS[3]
|
|
41
|
+
|
|
26
42
|
let uuid = ''
|
|
27
43
|
let resizeObserver = null
|
|
28
44
|
|
|
@@ -77,7 +93,7 @@ export default function setScrollGradient (config = {}) {
|
|
|
77
93
|
}
|
|
78
94
|
|
|
79
95
|
/**
|
|
80
|
-
* mostra ou esconde o span do gradient.
|
|
96
|
+
* mostra ou esconde o span do gradient com animação.
|
|
81
97
|
*
|
|
82
98
|
* @param {Direction} direction
|
|
83
99
|
* @param {boolean} show
|
|
@@ -87,7 +103,8 @@ export default function setScrollGradient (config = {}) {
|
|
|
87
103
|
|
|
88
104
|
if (!span) return
|
|
89
105
|
|
|
90
|
-
span.style.
|
|
106
|
+
span.style.opacity = show ? '1' : '0'
|
|
107
|
+
span.style.visibility = show ? 'visible' : 'hidden'
|
|
91
108
|
}
|
|
92
109
|
|
|
93
110
|
/**
|
|
@@ -112,16 +129,19 @@ export default function setScrollGradient (config = {}) {
|
|
|
112
129
|
Object.assign(span.style, {
|
|
113
130
|
pointerEvents: 'none',
|
|
114
131
|
height: isVertical ? size : '100%',
|
|
115
|
-
display: '
|
|
132
|
+
display: 'block',
|
|
116
133
|
position: 'absolute',
|
|
117
134
|
width: isVertical ? '100%' : size,
|
|
118
135
|
zIndex: 1,
|
|
136
|
+
opacity: '0',
|
|
137
|
+
visibility: 'hidden',
|
|
138
|
+
transition: 'opacity 0.3s ease-in-out, visibility 0.3s ease-in-out',
|
|
119
139
|
backgroundImage: (
|
|
120
140
|
`linear-gradient(
|
|
121
141
|
to ${getDirection(direction)},
|
|
122
142
|
rgba(${rgbParam}, 0) 0%,
|
|
123
|
-
rgba(${rgbParam},
|
|
124
|
-
|
|
143
|
+
rgba(${rgbParam}, ${level.mid}) 51%,
|
|
144
|
+
rgba(${rgbParam}, ${level.end}) 75%)`
|
|
125
145
|
)
|
|
126
146
|
})
|
|
127
147
|
|
|
@@ -154,13 +174,16 @@ export default function setScrollGradient (config = {}) {
|
|
|
154
174
|
const elementRect = element.getBoundingClientRect()
|
|
155
175
|
const parentRect = element.parentElement.getBoundingClientRect()
|
|
156
176
|
|
|
177
|
+
// pequena margem para garantir que o gradiente fique grudado ao elemento.
|
|
178
|
+
const safeArea = 1
|
|
179
|
+
|
|
157
180
|
/**
|
|
158
181
|
* diferença entre o bottom do pai e o bottom do filho, valor positivo significa
|
|
159
182
|
* que há espaço livre abaixo do filho.
|
|
160
183
|
*/
|
|
161
184
|
const distance = {
|
|
162
|
-
end: isVertical ? (parentRect.bottom - elementRect.bottom) : (parentRect.right - elementRect.right),
|
|
163
|
-
start: isVertical ? (elementRect.top - parentRect.top) : (elementRect.left - parentRect.left)
|
|
185
|
+
end: isVertical ? (parentRect.bottom - elementRect.bottom - safeArea) : (parentRect.right - elementRect.right - safeArea),
|
|
186
|
+
start: isVertical ? (elementRect.top - parentRect.top) - safeArea : (elementRect.left - parentRect.left) - safeArea
|
|
164
187
|
}
|
|
165
188
|
|
|
166
189
|
span.style[getDirection(direction)] = `${distance[direction]}px`
|
|
@@ -49,10 +49,17 @@ export default function (element, options = {}, cancelMouseDownTarget) {
|
|
|
49
49
|
function onMouseEnter (event) {
|
|
50
50
|
/**
|
|
51
51
|
* closest busca ancestral mais próximo de um elemento, ou seja, verifica se no event que recebo, tenho a classe no qual nao se deve aplicar o grab.
|
|
52
|
-
|
|
53
|
-
const targetElement = cancelMouseDownTarget ? event.target.closest(`.${cancelMouseDownTarget}`) : null
|
|
52
|
+
*/
|
|
54
53
|
|
|
55
|
-
|
|
54
|
+
const elementListToCancel = ['button', '[data-no-grab]']
|
|
55
|
+
|
|
56
|
+
if (cancelMouseDownTarget) {
|
|
57
|
+
elementListToCancel.push(`.${cancelMouseDownTarget}`)
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
const canCancelMouseDownTarget = elementListToCancel.some(tag => event.target.closest(tag))
|
|
61
|
+
|
|
62
|
+
if (canCancelMouseDownTarget) return
|
|
56
63
|
|
|
57
64
|
onEnter()
|
|
58
65
|
|
package/src/index.scss
CHANGED
|
@@ -13,6 +13,7 @@ $accent: var(--q-accent);
|
|
|
13
13
|
--qas-border-grey: #{$grey-4};
|
|
14
14
|
--qas-generic-border-radius: 4px;
|
|
15
15
|
--qas-generic-transition: 300ms;
|
|
16
|
+
--qas-magic-ai-gradient: linear-gradient(90deg, #0F54AE 0%, #C51162 100%);
|
|
16
17
|
}
|
|
17
18
|
|
|
18
19
|
$background-color: var(--qas-background-color);
|
|
@@ -86,6 +86,12 @@ export default {
|
|
|
86
86
|
return !!this.mx_filteredOptions.length
|
|
87
87
|
},
|
|
88
88
|
|
|
89
|
+
mx_hasNextPage () {
|
|
90
|
+
const { lastPage, page, hasCount, hasNextPage } = this.mx_pagination
|
|
91
|
+
|
|
92
|
+
return hasCount ? !!(lastPage && page <= lastPage) : hasNextPage
|
|
93
|
+
},
|
|
94
|
+
|
|
89
95
|
mx_hasOptionsToExclude () {
|
|
90
96
|
return !!this.optionsToExclude.length
|
|
91
97
|
}
|
|
@@ -98,7 +104,7 @@ export default {
|
|
|
98
104
|
|
|
99
105
|
this.mx_cachedOptions = []
|
|
100
106
|
|
|
101
|
-
this.mx_filterOptionsByStore('')
|
|
107
|
+
if (!this.disable) this.mx_filterOptionsByStore('')
|
|
102
108
|
|
|
103
109
|
setTimeout(() => this.$emit('update:modelValue', undefined))
|
|
104
110
|
}
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
import
|
|
1
|
+
import Dialog from '../dialog/Dialog.js'
|
|
2
|
+
import NotifySuccess from '../notify-success/NotifySuccess.js'
|
|
3
|
+
import NotifyError from '../notify-error/NotifyError.js'
|
|
2
4
|
import { getAction } from '@bildvitta/store-adapter'
|
|
3
5
|
import { useHistory } from '../../composables'
|
|
4
6
|
|
|
@@ -19,16 +21,12 @@ export default function (config = {}) {
|
|
|
19
21
|
const { entity, id, url } = deleteActionParams
|
|
20
22
|
|
|
21
23
|
const defaultDialogProps = {
|
|
22
|
-
|
|
24
|
+
useAutoCloseOnOk: false,
|
|
23
25
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
card: {
|
|
27
|
-
title: 'Excluir',
|
|
28
|
-
description: 'Tem certeza que deseja excluir este item?',
|
|
26
|
+
title: 'Excluir',
|
|
27
|
+
description: 'Tem certeza que deseja excluir este item?',
|
|
29
28
|
|
|
30
|
-
|
|
31
|
-
},
|
|
29
|
+
...dialogProps,
|
|
32
30
|
|
|
33
31
|
ok: {
|
|
34
32
|
label: 'Excluir',
|
|
@@ -3,7 +3,7 @@ type: component
|
|
|
3
3
|
meta:
|
|
4
4
|
desc: Plugin que implementa a action `destroy` do `StoreModule` adicionando comportamento de confirmação antes de excluir, este mesmo plugin é utilizado no componente `QasDelete`.
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
provide:
|
|
7
7
|
'this.$qas.delete(config)':
|
|
8
8
|
params:
|
|
9
9
|
config:
|