@pdfme/ui 3.4.2 → 3.4.3-dev.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.
- package/dist/index.es.js +61 -7
- package/dist/index.umd.js +3 -3
- package/dist/types/class.d.ts +1 -1
- package/package.json +1 -1
- package/src/i18n.ts +52 -0
package/dist/index.es.js
CHANGED
@@ -9237,7 +9237,7 @@ ieee754.write = function(a, s, $, _, _e, tt) {
|
|
9237
9237
|
throw new Error("BigInt not supported");
|
9238
9238
|
}
|
9239
9239
|
})(buffer$1);
|
9240
|
-
const langs = ["en", "ja", "ar", "th", "pl", "it", "de"], Lang = z.enum(langs);
|
9240
|
+
const langs = ["en", "ja", "ar", "th", "pl", "it", "de", "es"], Lang = z.enum(langs);
|
9241
9241
|
z.object({
|
9242
9242
|
// -----------------used in ui-----------------
|
9243
9243
|
cancel: z.string(),
|
@@ -75028,16 +75028,21 @@ const getBrowserVerticalFontAdjustments = (a, s, $, _) => {
|
|
75028
75028
|
if (isTextExceedingBoxWidth(a.slice(0, $ + 1), s))
|
75029
75029
|
return $;
|
75030
75030
|
return null;
|
75031
|
-
}, getSplitPosition = (a, s) => {
|
75031
|
+
}, isLineBreakableChar = (a) => [" ", "-", "—", "–"].includes(a), getSplitPosition = (a, s) => {
|
75032
75032
|
const $ = getOverPosition(a, s);
|
75033
75033
|
if ($ === null)
|
75034
75034
|
return a.length;
|
75035
|
-
|
75036
|
-
|
75035
|
+
if (a[$] === " ")
|
75036
|
+
return $;
|
75037
|
+
let _ = $ - 1;
|
75038
|
+
for (; _ >= 0; ) {
|
75039
|
+
if (isLineBreakableChar(a[_]))
|
75040
|
+
return _ + 1;
|
75037
75041
|
_--;
|
75038
|
-
|
75042
|
+
}
|
75043
|
+
return $;
|
75039
75044
|
}, getSplittedLines = (a, s) => {
|
75040
|
-
const $ = getSplitPosition(a, s), _ = a.substring(0, $), _e = a.substring($).trimStart();
|
75045
|
+
const $ = getSplitPosition(a, s), _ = a.substring(0, $).trimEnd(), _e = a.substring($).trimStart();
|
75041
75046
|
return _e === a ? [a] : _e.length === 0 ? [_] : [_, ...getSplittedLines(_e, s)];
|
75042
75047
|
}, calculateDynamicFontSize = async ({ textSchema: a, font: s, value: $, startingFontSize: _, _cache: _e }) => {
|
75043
75048
|
const { fontSize: tt, dynamicFontSize: nt, characterSpacing: at, width: ot, height: rt, lineHeight: st = DEFAULT_LINE_HEIGHT } = a, lt = _ || tt || DEFAULT_FONT_SIZE;
|
@@ -131962,6 +131967,54 @@ const _Upload = Upload, dictEn = {
|
|
131962
131967
|
"schemas.text.dynamicFontSize": "Dynamische Schriftgröße",
|
131963
131968
|
"schemas.barcodes.barColor": "Strichcodefarbe",
|
131964
131969
|
"schemas.barcodes.includetext": "Text anzeigen"
|
131970
|
+
}, dictEs = {
|
131971
|
+
cancel: "Cancelar",
|
131972
|
+
field: "campo",
|
131973
|
+
fieldName: "Nombre",
|
131974
|
+
align: "Alinear",
|
131975
|
+
width: "Anchura",
|
131976
|
+
height: "Altura",
|
131977
|
+
opacity: "Opacidad",
|
131978
|
+
rotate: "Rotar",
|
131979
|
+
edit: "Editar",
|
131980
|
+
plsInputName: "Introduce el nombre",
|
131981
|
+
fieldMustUniq: "El nombre del campo no es único",
|
131982
|
+
notUniq: "(Nombre no único)",
|
131983
|
+
noKeyName: "Sin nombre",
|
131984
|
+
fieldsList: "Lista de campos",
|
131985
|
+
addNewField: "Añadir un nuevo campo",
|
131986
|
+
editField: "Editar campo",
|
131987
|
+
type: "Tipo",
|
131988
|
+
errorOccurred: "Ocurrió un error",
|
131989
|
+
errorBulkUpdateFieldName: "No se puede confirmar el cambio porque el número de elementos ha cambiado.",
|
131990
|
+
commitBulkUpdateFieldName: "Confirmar cambios",
|
131991
|
+
bulkUpdateFieldName: "Actualizar en bloque el nombre de los campos",
|
131992
|
+
hexColorPrompt: "Introduce un código de color hexadecimal válido.",
|
131993
|
+
"schemas.color": "Color",
|
131994
|
+
"schemas.borderWidth": "Ancho del borde",
|
131995
|
+
"schemas.borderColor": "Color del borde",
|
131996
|
+
"schemas.textColor": "Color del texto",
|
131997
|
+
"schemas.bgColor": "Color del fondo",
|
131998
|
+
"schemas.horizontal": "Horizontal",
|
131999
|
+
"schemas.vertical": "Vertical",
|
132000
|
+
"schemas.left": "Izquierda",
|
132001
|
+
"schemas.center": "Centro",
|
132002
|
+
"schemas.right": "Derecha",
|
132003
|
+
"schemas.top": "Arriba",
|
132004
|
+
"schemas.middle": "Medio",
|
132005
|
+
"schemas.bottom": "Abajo",
|
132006
|
+
"schemas.text.fontName": "Nombre de la fuente",
|
132007
|
+
"schemas.text.size": "Tamaño",
|
132008
|
+
"schemas.text.spacing": "Espaciado",
|
132009
|
+
"schemas.text.textAlign": "Alineación del texto",
|
132010
|
+
"schemas.text.verticalAlign": "Alineación vertical",
|
132011
|
+
"schemas.text.lineHeight": "Altura de línea",
|
132012
|
+
"schemas.text.min": "Mín",
|
132013
|
+
"schemas.text.max": "Máx",
|
132014
|
+
"schemas.text.fit": "Ajustar",
|
132015
|
+
"schemas.text.dynamicFontSize": "Tamaño de fuente dinámico",
|
132016
|
+
"schemas.barcodes.barColor": "Color de la barra",
|
132017
|
+
"schemas.barcodes.includetext": "Incluir texto"
|
131965
132018
|
}, dictionaries = {
|
131966
132019
|
en: dictEn,
|
131967
132020
|
ja: dictJa,
|
@@ -131969,7 +132022,8 @@ const _Upload = Upload, dictEn = {
|
|
131969
132022
|
th: dictTh,
|
131970
132023
|
it: dictIt,
|
131971
132024
|
pl: dictPl,
|
131972
|
-
de: dictDe
|
132025
|
+
de: dictDe,
|
132026
|
+
es: dictEs
|
131973
132027
|
}, getDict = (a) => dictionaries[a] || dictionaries[DEFAULT_LANG], i18n = (a, s) => (s || getDict(DEFAULT_LANG))[a], I18nContext = reactExports.createContext(i18n), FontContext = reactExports.createContext(getDefaultFont()), PluginsRegistry = reactExports.createContext(builtInPlugins), OptionsContext = reactExports.createContext({});
|
131974
132028
|
var ArrowLeftOutlined$2 = { icon: { tag: "svg", attrs: { viewBox: "64 64 896 896", focusable: "false" }, children: [{ tag: "path", attrs: { d: "M872 474H286.9l350.2-304c5.6-4.9 2.2-14-5.2-14h-88.5c-3.9 0-7.6 1.4-10.5 3.9L155 487.8a31.96 31.96 0 000 48.3L535.1 866c1.5 1.3 3.3 2 5.2 2h91.5c7.4 0 10.8-9.2 5.2-14L286.9 550H872c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8z" } }] }, name: "arrow-left", theme: "outlined" };
|
131975
132029
|
const ArrowLeftOutlinedSvg = ArrowLeftOutlined$2;
|