@dile/crud
Advanced tools
Comparing version 0.0.39 to 0.0.40
@@ -83,3 +83,5 @@ import { LitElement, html, css } from 'lit'; | ||
<div class="actions" @action-success=${this.actionSuccess}> | ||
<dile-button gray .icon="${editIcon}" @click=${this.edit}>${this.updateLabelComputed(this.config.labels.updateAction, this.translations)}</dile-button> | ||
<dile-button gray .icon="${editIcon}" @click=${this.edit}> | ||
${this.startUpdateLabelComputed(this.config.labels.startUpdateAction, this.translations)} | ||
</dile-button> | ||
${this.actionsTemplate} | ||
@@ -86,0 +88,0 @@ </div> |
@@ -73,2 +73,3 @@ import { html } from "lit"; | ||
// updateAction: 'Save', | ||
// startUpdateAction: 'Edit', | ||
// insertWindowTitle: 'Create an item', | ||
@@ -75,0 +76,0 @@ // updateWindowTitle: 'Update an item', |
@@ -61,2 +61,5 @@ import { html } from "lit"; | ||
} | ||
startUpdateLabelComputed(label, translations) { | ||
return label ? label : translations?.start_update_label ? translations.start_update_label : 'Edit'; | ||
} | ||
helpLabelComputed(label, translations) { | ||
@@ -63,0 +66,0 @@ return label ? label : translations?.help_label ? translations.help_label : 'Help'; |
@@ -16,2 +16,3 @@ export const translations = { | ||
update_label: "Update", | ||
start_update_label: "Edit", | ||
delete_label: "Delete", | ||
@@ -18,0 +19,0 @@ cancel_label: "Cancel", |
@@ -16,2 +16,3 @@ export const translations = { | ||
update_label: "Actualizar", | ||
start_update_label: "Editar", | ||
delete_label: "Borrar", | ||
@@ -18,0 +19,0 @@ cancel_label: "Cancelar", |
{ | ||
"name": "@dile/crud", | ||
"version": "0.0.39", | ||
"version": "0.0.40", | ||
"description": "Components to create a generic crud system based on Web Components and Lit", | ||
@@ -34,3 +34,3 @@ "main": "index.js", | ||
}, | ||
"gitHead": "47a3da898c4ef2856603eb98b41c8e3b09bef1df" | ||
"gitHead": "04e4cb1ee801ba221847efb9e8067102de43192e" | ||
} |
110291
3328