grav-svelte 0.1.236 → 0.1.237
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/dist/CRUD/CrudFilters.svelte +17 -9
- package/dist/CRUD/CrudFilters.svelte.d.ts +8 -0
- package/dist/CRUD/CrudWrapper.svelte +16 -0
- package/dist/CRUD/CrudWrapper.svelte.d.ts +8 -0
- package/dist/Inputs/InputFormCascade.svelte +2 -0
- package/dist/Inputs/InputFormSelect.svelte +2 -1
- package/dist/Inputs/InputFormSelect.svelte.d.ts +1 -0
- package/package.json +1 -1
|
@@ -27,6 +27,14 @@
|
|
|
27
27
|
export let showSettingsButton: boolean = false;
|
|
28
28
|
export let showMostrandoInput: boolean = true;
|
|
29
29
|
export let Titulo_Crud: string;
|
|
30
|
+
export let tooltipAgregar: string = 'Agregar';
|
|
31
|
+
export let tooltipImportarExcel: string = 'Importar Excel';
|
|
32
|
+
export let tooltipVerFiltros: string = 'Ver filtros';
|
|
33
|
+
export let tooltipConfiguracion: string = 'Configuración';
|
|
34
|
+
export let tooltipLimpiar: string = 'Borrar filtro';
|
|
35
|
+
export let labelLimpiar: string = 'Limpiar';
|
|
36
|
+
export let tooltipFiltrar: string = 'Aplicar filtro';
|
|
37
|
+
export let labelFiltrar: string = 'Filtrar';
|
|
30
38
|
|
|
31
39
|
// Dynamic grid columns calculation
|
|
32
40
|
$: gridColumns = Math.min(Filtros.length, 6);
|
|
@@ -177,7 +185,7 @@
|
|
|
177
185
|
<div class="filters-controls">
|
|
178
186
|
<div class="filters-actions">
|
|
179
187
|
{#if showAddButton}
|
|
180
|
-
<Tooltip text=
|
|
188
|
+
<Tooltip text={tooltipAgregar}>
|
|
181
189
|
<!-- svelte-ignore a11y_consider_explicit_label -->
|
|
182
190
|
<button
|
|
183
191
|
class="action-button"
|
|
@@ -202,7 +210,7 @@
|
|
|
202
210
|
</Tooltip>
|
|
203
211
|
{/if}
|
|
204
212
|
{#if showImportButton}
|
|
205
|
-
<Tooltip text=
|
|
213
|
+
<Tooltip text={tooltipImportarExcel}>
|
|
206
214
|
<!-- svelte-ignore a11y_consider_explicit_label -->
|
|
207
215
|
<button
|
|
208
216
|
class="action-button"
|
|
@@ -230,7 +238,7 @@
|
|
|
230
238
|
</Tooltip>
|
|
231
239
|
{/if}
|
|
232
240
|
{#if Filtros && Filtros.length > 0}
|
|
233
|
-
<Tooltip text=
|
|
241
|
+
<Tooltip text={tooltipVerFiltros}>
|
|
234
242
|
{#if showFilters}
|
|
235
243
|
<button
|
|
236
244
|
type="button"
|
|
@@ -251,7 +259,7 @@
|
|
|
251
259
|
</Tooltip>
|
|
252
260
|
{/if}
|
|
253
261
|
{#if showSettingsButton}
|
|
254
|
-
<Tooltip text=
|
|
262
|
+
<Tooltip text={tooltipConfiguracion}>
|
|
255
263
|
<button
|
|
256
264
|
type="button"
|
|
257
265
|
on:click={() => dispatch("settings")}
|
|
@@ -348,25 +356,25 @@
|
|
|
348
356
|
<!-- Btn de aplicar filtro -->
|
|
349
357
|
<div class="filters-actions">
|
|
350
358
|
<!-- Btn de limpiar filtros -->
|
|
351
|
-
<Tooltip text=
|
|
359
|
+
<Tooltip text={tooltipLimpiar}>
|
|
352
360
|
<!-- svelte-ignore a11y_consider_explicit_label -->
|
|
353
361
|
<button
|
|
354
362
|
type="button"
|
|
355
363
|
on:click={() => clearFilters()}
|
|
356
364
|
class="filter-button"
|
|
357
365
|
>
|
|
358
|
-
|
|
366
|
+
{labelLimpiar}
|
|
359
367
|
</button>
|
|
360
368
|
</Tooltip>
|
|
361
|
-
<Tooltip text=
|
|
369
|
+
<Tooltip text={tooltipFiltrar}>
|
|
362
370
|
<!-- svelte-ignore a11y_consider_explicit_label -->
|
|
363
371
|
<button
|
|
364
372
|
type="button"
|
|
365
373
|
on:click={() => actualizarFiltro()}
|
|
366
374
|
class="filter-button filter-apply-button"
|
|
367
|
-
aria-label=
|
|
375
|
+
aria-label={tooltipFiltrar}
|
|
368
376
|
>
|
|
369
|
-
|
|
377
|
+
{labelFiltrar}
|
|
370
378
|
</button>
|
|
371
379
|
</Tooltip>
|
|
372
380
|
</div>
|
|
@@ -11,6 +11,14 @@ declare const __propDef: {
|
|
|
11
11
|
showSettingsButton?: boolean;
|
|
12
12
|
showMostrandoInput?: boolean;
|
|
13
13
|
Titulo_Crud: string;
|
|
14
|
+
tooltipAgregar?: string;
|
|
15
|
+
tooltipImportarExcel?: string;
|
|
16
|
+
tooltipVerFiltros?: string;
|
|
17
|
+
tooltipConfiguracion?: string;
|
|
18
|
+
tooltipLimpiar?: string;
|
|
19
|
+
labelLimpiar?: string;
|
|
20
|
+
tooltipFiltrar?: string;
|
|
21
|
+
labelFiltrar?: string;
|
|
14
22
|
};
|
|
15
23
|
events: {
|
|
16
24
|
add: CustomEvent<any>;
|
|
@@ -24,6 +24,14 @@
|
|
|
24
24
|
export let showSettingsButton: boolean = false;
|
|
25
25
|
export let showMostrandoInput: boolean = true;
|
|
26
26
|
export let Titulo_Crud: string;
|
|
27
|
+
export let tooltipAgregar: string = 'Agregar';
|
|
28
|
+
export let tooltipImportarExcel: string = 'Importar Excel';
|
|
29
|
+
export let tooltipVerFiltros: string = 'Ver filtros';
|
|
30
|
+
export let tooltipConfiguracion: string = 'Configuración';
|
|
31
|
+
export let tooltipLimpiar: string = 'Borrar filtro';
|
|
32
|
+
export let labelLimpiar: string = 'Limpiar';
|
|
33
|
+
export let tooltipFiltrar: string = 'Aplicar filtro';
|
|
34
|
+
export let labelFiltrar: string = 'Filtrar';
|
|
27
35
|
export let dragEnabled: boolean = false;
|
|
28
36
|
export let orderField: string = "inOrden";
|
|
29
37
|
export let minHeightScreen: boolean = false;
|
|
@@ -143,6 +151,14 @@
|
|
|
143
151
|
{showSettingsButton}
|
|
144
152
|
{showMostrandoInput}
|
|
145
153
|
{Titulo_Crud}
|
|
154
|
+
{tooltipAgregar}
|
|
155
|
+
{tooltipImportarExcel}
|
|
156
|
+
{tooltipVerFiltros}
|
|
157
|
+
{tooltipConfiguracion}
|
|
158
|
+
{tooltipLimpiar}
|
|
159
|
+
{labelLimpiar}
|
|
160
|
+
{tooltipFiltrar}
|
|
161
|
+
{labelFiltrar}
|
|
146
162
|
/>
|
|
147
163
|
</div>
|
|
148
164
|
<div class="crud-table-container crud-anim-item crud-anim-table">
|
|
@@ -18,6 +18,14 @@ declare const __propDef: {
|
|
|
18
18
|
showSettingsButton?: boolean;
|
|
19
19
|
showMostrandoInput?: boolean;
|
|
20
20
|
Titulo_Crud: string;
|
|
21
|
+
tooltipAgregar?: string;
|
|
22
|
+
tooltipImportarExcel?: string;
|
|
23
|
+
tooltipVerFiltros?: string;
|
|
24
|
+
tooltipConfiguracion?: string;
|
|
25
|
+
tooltipLimpiar?: string;
|
|
26
|
+
labelLimpiar?: string;
|
|
27
|
+
tooltipFiltrar?: string;
|
|
28
|
+
labelFiltrar?: string;
|
|
21
29
|
dragEnabled?: boolean;
|
|
22
30
|
orderField?: string;
|
|
23
31
|
minHeightScreen?: boolean;
|
|
@@ -79,6 +79,7 @@
|
|
|
79
79
|
onClear={() => handleChange(0, null, level.field)}
|
|
80
80
|
showPlusIcon={level.showPlusIcon ?? false}
|
|
81
81
|
onPlusClick={level.onPlusClick ?? (() => {})}
|
|
82
|
+
placeholder={level.placeholder}
|
|
82
83
|
/>
|
|
83
84
|
{/await}
|
|
84
85
|
{/if}
|
|
@@ -99,6 +100,7 @@
|
|
|
99
100
|
onClear={() => handleChange(i, null, level.field)}
|
|
100
101
|
showPlusIcon={level.showPlusIcon ?? false}
|
|
101
102
|
onPlusClick={level.onPlusClick ?? (() => {})}
|
|
103
|
+
placeholder={level.placeholder}
|
|
102
104
|
/>
|
|
103
105
|
{/await}
|
|
104
106
|
{:else}
|
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
export let showPlusIcon = false;
|
|
21
21
|
export let onPlusClick: () => void = () => {};
|
|
22
22
|
export let multiple = false;
|
|
23
|
+
export let placeholder: string | undefined = undefined;
|
|
23
24
|
|
|
24
25
|
let containerEl: HTMLDivElement;
|
|
25
26
|
|
|
@@ -129,7 +130,7 @@
|
|
|
129
130
|
class="select-input"
|
|
130
131
|
inputStyles="font-size: 16px; color: currentColor !important; background-color: transparent;"
|
|
131
132
|
containerStyles="font-size: 16px; background-color: transparent; border: var(--grav-crud-input-border-width) solid currentColor; border-radius: 0.5rem;"
|
|
132
|
-
placeholder={multiple ? "Seleccione opciones" : "Seleccione una opción"}
|
|
133
|
+
placeholder={placeholder ?? (multiple ? "Seleccione opciones" : "Seleccione una opción")}
|
|
133
134
|
--placeholder-color="currentColor"
|
|
134
135
|
--chevron-color="currentColor"
|
|
135
136
|
--item-color="black"
|