grav-svelte 0.0.71 → 0.0.73

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.
@@ -19,6 +19,8 @@
19
19
  export let loading: boolean = false;
20
20
  export let showAddButton: boolean = true;
21
21
  export let showImportButton: boolean = true;
22
+ export let showExcelButton: boolean = true;
23
+ export let showPdfButton: boolean = true;
22
24
  export let Titulo_Crud: string;
23
25
  export let dragEnabled: boolean = false;
24
26
  export let orderField: string = "inOrden";
@@ -145,22 +147,28 @@
145
147
  />
146
148
  </div>
147
149
 
148
- <div class="export-buttons">
149
- <button
150
- type="button"
151
- on:click={() => handleExport("excel")}
152
- class="export-button excel-button"
153
- >
154
- <i class="fas fa-file-excel"></i> EXCEL
155
- </button>
156
- <button
157
- type="button"
158
- on:click={() => handleExport("pdf")}
159
- class="export-button pdf-button"
160
- >
161
- <i class="far fa-file-pdf"></i> PDF
162
- </button>
163
- </div>
150
+ {#if showExcelButton || showPdfButton}
151
+ <div class="export-buttons">
152
+ {#if showExcelButton}
153
+ <button
154
+ type="button"
155
+ on:click={() => handleExport("excel")}
156
+ class="export-button excel-button"
157
+ >
158
+ <i class="fas fa-file-excel"></i> EXCEL
159
+ </button>
160
+ {/if}
161
+ {#if showPdfButton}
162
+ <button
163
+ type="button"
164
+ on:click={() => handleExport("pdf")}
165
+ class="export-button pdf-button"
166
+ >
167
+ <i class="far fa-file-pdf"></i> PDF
168
+ </button>
169
+ {/if}
170
+ </div>
171
+ {/if}
164
172
  </div>
165
173
 
166
174
  <style>
@@ -13,6 +13,8 @@ declare const __propDef: {
13
13
  loading?: boolean;
14
14
  showAddButton?: boolean;
15
15
  showImportButton?: boolean;
16
+ showExcelButton?: boolean;
17
+ showPdfButton?: boolean;
16
18
  Titulo_Crud: string;
17
19
  dragEnabled?: boolean;
18
20
  orderField?: string;
@@ -177,6 +177,8 @@ export interface CrudWrapperProps {
177
177
  loading?: boolean;
178
178
  showAddButton?: boolean;
179
179
  showImportButton?: boolean;
180
+ showExcelButton?: boolean;
181
+ showPdfButton?: boolean;
180
182
  /**
181
183
  * Field name that contains the unique ID for each row.
182
184
  * Defaults to 'id' if not specified.
@@ -562,6 +562,7 @@
562
562
  align-items: center;
563
563
  justify-content: center;
564
564
  cursor: pointer;
565
+ font-family: var(--grav-crud-header-font-family, "mundial", sans-serif);
565
566
  }
566
567
 
567
568
  .dual-text-button:hover {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "grav-svelte",
3
- "version": "0.0.71",
3
+ "version": "0.0.73",
4
4
  "description": "A collection of Svelte components",
5
5
  "license": "MIT",
6
6
  "scripts": {