antd-mobile 5.8.1 → 5.8.2
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/2x/cjs/components/image-uploader/image-uploader.js +2 -1
- package/2x/cjs/components/popover/popover.js +0 -1
- package/2x/cjs/locales/es-ES.d.ts +102 -0
- package/2x/cjs/locales/es-ES.js +115 -0
- package/2x/cjs/utils/measure-css-length.d.ts +1 -1
- package/2x/cjs/utils/measure-css-length.js +8 -0
- package/2x/es/components/image-uploader/image-uploader.js +2 -1
- package/2x/es/components/popover/popover.js +0 -1
- package/2x/es/locales/es-ES.d.ts +102 -0
- package/2x/es/locales/es-ES.js +105 -0
- package/2x/es/utils/measure-css-length.d.ts +1 -1
- package/2x/es/utils/measure-css-length.js +8 -0
- package/2x/package.json +1 -1
- package/cjs/components/image-uploader/image-uploader.js +2 -1
- package/cjs/components/popover/popover.js +0 -1
- package/cjs/locales/es-ES.d.ts +102 -0
- package/cjs/locales/es-ES.js +115 -0
- package/cjs/utils/measure-css-length.d.ts +1 -1
- package/cjs/utils/measure-css-length.js +8 -0
- package/es/components/image-uploader/image-uploader.js +2 -1
- package/es/components/popover/popover.js +0 -1
- package/es/locales/es-ES.d.ts +102 -0
- package/es/locales/es-ES.js +105 -0
- package/es/utils/measure-css-length.d.ts +1 -1
- package/es/utils/measure-css-length.js +8 -0
- package/package.json +1 -1
- package/umd/antd-mobile.js +1 -1
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
var _mergeLocale = require("../utils/merge-locale");
|
|
9
|
+
|
|
10
|
+
var _base = require("./base");
|
|
11
|
+
|
|
12
|
+
const typeTemplate = '${label} no es un ${type} válido';
|
|
13
|
+
const esES = (0, _mergeLocale.mergeLocale)(_base.base, {
|
|
14
|
+
locale: 'es',
|
|
15
|
+
common: {
|
|
16
|
+
confirm: 'Confirmar',
|
|
17
|
+
cancel: 'Cancelar',
|
|
18
|
+
loading: 'Cargando...'
|
|
19
|
+
},
|
|
20
|
+
Calendar: {
|
|
21
|
+
markItems: ['Lun', 'Mar', 'Mie', 'Jue', 'Vie', 'Sab', 'Dom'],
|
|
22
|
+
renderYearAndMonth: (year, month) => `${year}/${month}`
|
|
23
|
+
},
|
|
24
|
+
Cascader: {
|
|
25
|
+
placeholder: 'Seleccionando'
|
|
26
|
+
},
|
|
27
|
+
Dialog: {
|
|
28
|
+
ok: 'OK'
|
|
29
|
+
},
|
|
30
|
+
ErrorBlock: {
|
|
31
|
+
default: {
|
|
32
|
+
title: 'Oops, algo salió mal',
|
|
33
|
+
description: 'Por favor espere un minuto e intente nuevamente'
|
|
34
|
+
},
|
|
35
|
+
busy: {
|
|
36
|
+
title: 'Oops, no está cargando',
|
|
37
|
+
description: 'Intente refrescar la página'
|
|
38
|
+
},
|
|
39
|
+
disconnected: {
|
|
40
|
+
title: 'La red se encuentra ocupada',
|
|
41
|
+
description: 'Intente refrescar la página'
|
|
42
|
+
},
|
|
43
|
+
empty: {
|
|
44
|
+
title: "Hmm, no pudimos encontrar eso...",
|
|
45
|
+
description: 'Quieres intentar una nueva búsqueda?'
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
Form: {
|
|
49
|
+
required: 'Requerido',
|
|
50
|
+
optional: 'Opcional',
|
|
51
|
+
defaultValidateMessages: {
|
|
52
|
+
default: 'Error de validación para el campo ${label}',
|
|
53
|
+
required: 'Por favor ingrese ${label}',
|
|
54
|
+
enum: '${label} debe ser uno de los siguientes [${enum}]',
|
|
55
|
+
whitespace: '${label} no puede ser un caracter en blanco',
|
|
56
|
+
date: {
|
|
57
|
+
format: '${label} el formato de fecha es inválido',
|
|
58
|
+
parse: '${label} no puede ser convertido a fecha',
|
|
59
|
+
invalid: '${label} no es una fecha válida'
|
|
60
|
+
},
|
|
61
|
+
types: {
|
|
62
|
+
string: typeTemplate,
|
|
63
|
+
method: typeTemplate,
|
|
64
|
+
array: typeTemplate,
|
|
65
|
+
object: typeTemplate,
|
|
66
|
+
number: typeTemplate,
|
|
67
|
+
date: typeTemplate,
|
|
68
|
+
boolean: typeTemplate,
|
|
69
|
+
integer: typeTemplate,
|
|
70
|
+
float: typeTemplate,
|
|
71
|
+
regexp: typeTemplate,
|
|
72
|
+
email: typeTemplate,
|
|
73
|
+
url: typeTemplate,
|
|
74
|
+
hex: typeTemplate
|
|
75
|
+
},
|
|
76
|
+
string: {
|
|
77
|
+
len: '${label} debe tener ${len} caracteres',
|
|
78
|
+
min: '${label} debe tener al menos ${min} caracteres',
|
|
79
|
+
max: '${label} debe tener como mucho ${max} caracteres',
|
|
80
|
+
range: '${label} debe tener entre ${min}-${max} caracteres'
|
|
81
|
+
},
|
|
82
|
+
number: {
|
|
83
|
+
len: '${label} debe ser igual a ${len}',
|
|
84
|
+
min: '${label} debe ser mínimo ${min}',
|
|
85
|
+
max: '${label} debe ser máximo ${max}',
|
|
86
|
+
range: '${label} debe ser entre ${min}-${max}'
|
|
87
|
+
},
|
|
88
|
+
array: {
|
|
89
|
+
len: 'Debe ser ${len} ${label}',
|
|
90
|
+
min: 'Al menos ${min} ${label}',
|
|
91
|
+
max: 'Como mucho ${max} ${label}',
|
|
92
|
+
range: 'La cantidad de ${label} debe ser entre ${min}-${max}'
|
|
93
|
+
},
|
|
94
|
+
pattern: {
|
|
95
|
+
mismatch: '${label} no coincide con el patrón ${pattern}'
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
},
|
|
99
|
+
ImageUploader: {
|
|
100
|
+
uploading: 'Subiendo...'
|
|
101
|
+
},
|
|
102
|
+
Mask: {
|
|
103
|
+
name: 'Máscara'
|
|
104
|
+
},
|
|
105
|
+
Modal: {
|
|
106
|
+
ok: 'OK'
|
|
107
|
+
},
|
|
108
|
+
PullToRefresh: {
|
|
109
|
+
pulling: 'Desplácese hacia abajo para refrescar',
|
|
110
|
+
canRelease: 'Suelte para refrescar inmediatamente',
|
|
111
|
+
complete: 'Refrescó exitosamente'
|
|
112
|
+
}
|
|
113
|
+
});
|
|
114
|
+
var _default = esES;
|
|
115
|
+
exports.default = _default;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function measureCSSLength(raw: string): number;
|
|
1
|
+
export declare function measureCSSLength(raw: string | undefined | null): number;
|
|
@@ -10,6 +10,14 @@ var _isDev = require("./is-dev");
|
|
|
10
10
|
var _devLog = require("./dev-log");
|
|
11
11
|
|
|
12
12
|
function measureCSSLength(raw) {
|
|
13
|
+
if (raw === null || raw === undefined) {
|
|
14
|
+
if (_isDev.isDev) {
|
|
15
|
+
(0, _devLog.devError)('Global', 'Seems like the you will encounter a style messed problem. Please check the browser environment to make sure it supports CSS variables.');
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
return 0;
|
|
19
|
+
}
|
|
20
|
+
|
|
13
21
|
const withUnit = raw.trim();
|
|
14
22
|
|
|
15
23
|
if (withUnit.endsWith('px')) {
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
declare const esES: {
|
|
2
|
+
locale: string;
|
|
3
|
+
common: {
|
|
4
|
+
confirm: string;
|
|
5
|
+
cancel: string;
|
|
6
|
+
loading: string;
|
|
7
|
+
};
|
|
8
|
+
Calendar: {
|
|
9
|
+
markItems: string[];
|
|
10
|
+
renderYearAndMonth: (year: number, month: number) => string;
|
|
11
|
+
};
|
|
12
|
+
Cascader: {
|
|
13
|
+
placeholder: string;
|
|
14
|
+
};
|
|
15
|
+
Dialog: {
|
|
16
|
+
ok: string;
|
|
17
|
+
};
|
|
18
|
+
ErrorBlock: {
|
|
19
|
+
default: {
|
|
20
|
+
title: string;
|
|
21
|
+
description: string;
|
|
22
|
+
};
|
|
23
|
+
busy: {
|
|
24
|
+
title: string;
|
|
25
|
+
description: string;
|
|
26
|
+
};
|
|
27
|
+
disconnected: {
|
|
28
|
+
title: string;
|
|
29
|
+
description: string;
|
|
30
|
+
};
|
|
31
|
+
empty: {
|
|
32
|
+
title: string;
|
|
33
|
+
description: string;
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
Form: {
|
|
37
|
+
required: string;
|
|
38
|
+
optional: string;
|
|
39
|
+
defaultValidateMessages: {
|
|
40
|
+
default: string;
|
|
41
|
+
required: string;
|
|
42
|
+
enum: string;
|
|
43
|
+
whitespace: string;
|
|
44
|
+
date: {
|
|
45
|
+
format: string;
|
|
46
|
+
parse: string;
|
|
47
|
+
invalid: string;
|
|
48
|
+
};
|
|
49
|
+
types: {
|
|
50
|
+
string: string;
|
|
51
|
+
method: string;
|
|
52
|
+
array: string;
|
|
53
|
+
object: string;
|
|
54
|
+
number: string;
|
|
55
|
+
date: string;
|
|
56
|
+
boolean: string;
|
|
57
|
+
integer: string;
|
|
58
|
+
float: string;
|
|
59
|
+
regexp: string;
|
|
60
|
+
email: string;
|
|
61
|
+
url: string;
|
|
62
|
+
hex: string;
|
|
63
|
+
};
|
|
64
|
+
string: {
|
|
65
|
+
len: string;
|
|
66
|
+
min: string;
|
|
67
|
+
max: string;
|
|
68
|
+
range: string;
|
|
69
|
+
};
|
|
70
|
+
number: {
|
|
71
|
+
len: string;
|
|
72
|
+
min: string;
|
|
73
|
+
max: string;
|
|
74
|
+
range: string;
|
|
75
|
+
};
|
|
76
|
+
array: {
|
|
77
|
+
len: string;
|
|
78
|
+
min: string;
|
|
79
|
+
max: string;
|
|
80
|
+
range: string;
|
|
81
|
+
};
|
|
82
|
+
pattern: {
|
|
83
|
+
mismatch: string;
|
|
84
|
+
};
|
|
85
|
+
};
|
|
86
|
+
};
|
|
87
|
+
ImageUploader: {
|
|
88
|
+
uploading: string;
|
|
89
|
+
};
|
|
90
|
+
Mask: {
|
|
91
|
+
name: string;
|
|
92
|
+
};
|
|
93
|
+
Modal: {
|
|
94
|
+
ok: string;
|
|
95
|
+
};
|
|
96
|
+
PullToRefresh: {
|
|
97
|
+
pulling: string;
|
|
98
|
+
canRelease: string;
|
|
99
|
+
complete: string;
|
|
100
|
+
};
|
|
101
|
+
};
|
|
102
|
+
export default esES;
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { mergeLocale } from '../utils/merge-locale';
|
|
2
|
+
import { base } from './base';
|
|
3
|
+
const typeTemplate = '${label} no es un ${type} válido';
|
|
4
|
+
const esES = mergeLocale(base, {
|
|
5
|
+
locale: 'es',
|
|
6
|
+
common: {
|
|
7
|
+
confirm: 'Confirmar',
|
|
8
|
+
cancel: 'Cancelar',
|
|
9
|
+
loading: 'Cargando...'
|
|
10
|
+
},
|
|
11
|
+
Calendar: {
|
|
12
|
+
markItems: ['Lun', 'Mar', 'Mie', 'Jue', 'Vie', 'Sab', 'Dom'],
|
|
13
|
+
renderYearAndMonth: (year, month) => `${year}/${month}`
|
|
14
|
+
},
|
|
15
|
+
Cascader: {
|
|
16
|
+
placeholder: 'Seleccionando'
|
|
17
|
+
},
|
|
18
|
+
Dialog: {
|
|
19
|
+
ok: 'OK'
|
|
20
|
+
},
|
|
21
|
+
ErrorBlock: {
|
|
22
|
+
default: {
|
|
23
|
+
title: 'Oops, algo salió mal',
|
|
24
|
+
description: 'Por favor espere un minuto e intente nuevamente'
|
|
25
|
+
},
|
|
26
|
+
busy: {
|
|
27
|
+
title: 'Oops, no está cargando',
|
|
28
|
+
description: 'Intente refrescar la página'
|
|
29
|
+
},
|
|
30
|
+
disconnected: {
|
|
31
|
+
title: 'La red se encuentra ocupada',
|
|
32
|
+
description: 'Intente refrescar la página'
|
|
33
|
+
},
|
|
34
|
+
empty: {
|
|
35
|
+
title: "Hmm, no pudimos encontrar eso...",
|
|
36
|
+
description: 'Quieres intentar una nueva búsqueda?'
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
Form: {
|
|
40
|
+
required: 'Requerido',
|
|
41
|
+
optional: 'Opcional',
|
|
42
|
+
defaultValidateMessages: {
|
|
43
|
+
default: 'Error de validación para el campo ${label}',
|
|
44
|
+
required: 'Por favor ingrese ${label}',
|
|
45
|
+
enum: '${label} debe ser uno de los siguientes [${enum}]',
|
|
46
|
+
whitespace: '${label} no puede ser un caracter en blanco',
|
|
47
|
+
date: {
|
|
48
|
+
format: '${label} el formato de fecha es inválido',
|
|
49
|
+
parse: '${label} no puede ser convertido a fecha',
|
|
50
|
+
invalid: '${label} no es una fecha válida'
|
|
51
|
+
},
|
|
52
|
+
types: {
|
|
53
|
+
string: typeTemplate,
|
|
54
|
+
method: typeTemplate,
|
|
55
|
+
array: typeTemplate,
|
|
56
|
+
object: typeTemplate,
|
|
57
|
+
number: typeTemplate,
|
|
58
|
+
date: typeTemplate,
|
|
59
|
+
boolean: typeTemplate,
|
|
60
|
+
integer: typeTemplate,
|
|
61
|
+
float: typeTemplate,
|
|
62
|
+
regexp: typeTemplate,
|
|
63
|
+
email: typeTemplate,
|
|
64
|
+
url: typeTemplate,
|
|
65
|
+
hex: typeTemplate
|
|
66
|
+
},
|
|
67
|
+
string: {
|
|
68
|
+
len: '${label} debe tener ${len} caracteres',
|
|
69
|
+
min: '${label} debe tener al menos ${min} caracteres',
|
|
70
|
+
max: '${label} debe tener como mucho ${max} caracteres',
|
|
71
|
+
range: '${label} debe tener entre ${min}-${max} caracteres'
|
|
72
|
+
},
|
|
73
|
+
number: {
|
|
74
|
+
len: '${label} debe ser igual a ${len}',
|
|
75
|
+
min: '${label} debe ser mínimo ${min}',
|
|
76
|
+
max: '${label} debe ser máximo ${max}',
|
|
77
|
+
range: '${label} debe ser entre ${min}-${max}'
|
|
78
|
+
},
|
|
79
|
+
array: {
|
|
80
|
+
len: 'Debe ser ${len} ${label}',
|
|
81
|
+
min: 'Al menos ${min} ${label}',
|
|
82
|
+
max: 'Como mucho ${max} ${label}',
|
|
83
|
+
range: 'La cantidad de ${label} debe ser entre ${min}-${max}'
|
|
84
|
+
},
|
|
85
|
+
pattern: {
|
|
86
|
+
mismatch: '${label} no coincide con el patrón ${pattern}'
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
ImageUploader: {
|
|
91
|
+
uploading: 'Subiendo...'
|
|
92
|
+
},
|
|
93
|
+
Mask: {
|
|
94
|
+
name: 'Máscara'
|
|
95
|
+
},
|
|
96
|
+
Modal: {
|
|
97
|
+
ok: 'OK'
|
|
98
|
+
},
|
|
99
|
+
PullToRefresh: {
|
|
100
|
+
pulling: 'Desplácese hacia abajo para refrescar',
|
|
101
|
+
canRelease: 'Suelte para refrescar inmediatamente',
|
|
102
|
+
complete: 'Refrescó exitosamente'
|
|
103
|
+
}
|
|
104
|
+
});
|
|
105
|
+
export default esES;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function measureCSSLength(raw: string): number;
|
|
1
|
+
export declare function measureCSSLength(raw: string | undefined | null): number;
|
|
@@ -1,6 +1,14 @@
|
|
|
1
1
|
import { isDev } from './is-dev';
|
|
2
2
|
import { devError } from './dev-log';
|
|
3
3
|
export function measureCSSLength(raw) {
|
|
4
|
+
if (raw === null || raw === undefined) {
|
|
5
|
+
if (isDev) {
|
|
6
|
+
devError('Global', 'Seems like the you will encounter a style messed problem. Please check the browser environment to make sure it supports CSS variables.');
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
return 0;
|
|
10
|
+
}
|
|
11
|
+
|
|
4
12
|
const withUnit = raw.trim();
|
|
5
13
|
|
|
6
14
|
if (withUnit.endsWith('px')) {
|