dv-web-components 1.0.6 → 1.0.7

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.
@@ -10,6 +10,8 @@ export class AppInput extends HTMLElement {
10
10
  get name(): string;
11
11
  set type(val: string);
12
12
  get type(): string;
13
+ set placeholder(val: string);
14
+ get placeholder(): string;
13
15
  set disabled(val: boolean);
14
16
  get disabled(): boolean;
15
17
  set required(val: boolean);
@@ -207,6 +207,15 @@ export class AppInput extends HTMLElement {
207
207
  this.setAttribute('type', val);
208
208
  }
209
209
 
210
+ get placeholder() {
211
+ return this.getAttribute('placeholder') || '';
212
+ }
213
+
214
+ set placeholder(val) {
215
+ if (val) this.setAttribute('placeholder', val);
216
+ else this.removeAttribute('placeholder');
217
+ }
218
+
210
219
  get disabled() {
211
220
  return this.hasAttribute('disabled');
212
221
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dv-web-components",
3
- "version": "1.0.6",
3
+ "version": "1.0.7",
4
4
  "description": "Librería de Web Components nativos y accesibles",
5
5
  "type": "module",
6
6
  "main": "./index.js",