Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/b input value type #1101

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 33 additions & 1 deletion components-lock.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"hash": "90998e4c7a0a5a2478284963c99dcdb2aa52779fe00c55335be5845844fcc130",
"hash": "c90f98f3c814bab5a159949fb38f8e8910986f366aa2af78293c76d96ac1abcc",
"data": {
"%data": "%data:Map",
"%data:Map": [
Expand Down Expand Up @@ -1195,6 +1195,38 @@
"etpl": null
}
],
[
"b-virtual-scroll-new",
{
"index": "src/base/b-virtual-scroll-new/index.js",
"declaration": {
"name": "b-virtual-scroll-new",
"parent": "i-data",
"dependencies": [],
"libs": []
},
"name": "b-virtual-scroll-new",
"parent": "i-data",
"dependencies": [],
"libs": [],
"resolvedLibs": {
"%data": "%data:Set",
"%data:Set": []
},
"resolvedOwnLibs": {
"%data": "%data:Set",
"%data:Set": []
},
"type": "block",
"mixin": false,
"logic": "src/base/b-virtual-scroll-new/b-virtual-scroll-new.ts",
"styles": [
"src/base/b-virtual-scroll-new/b-virtual-scroll-new.styl"
],
"tpl": "src/base/b-virtual-scroll-new/b-virtual-scroll-new.ss",
"etpl": null
}
],
[
"b-window",
{
Expand Down
88 changes: 83 additions & 5 deletions fat-html.components-lock.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"hash": "2a22eb53756a6e760e1a06bf1948e34c9f61422a803f720888f02d15cf887846",
"hash": "514ba9b05a600c0c69394345608c803932507bcd6cde154f00a95cb0eaf7ecf1",
"data": {
"%data": "%data:Map",
"%data:Map": [
Expand Down Expand Up @@ -1195,6 +1195,38 @@
"etpl": null
}
],
[
"b-virtual-scroll-new",
{
"index": "src/base/b-virtual-scroll-new/index.js",
"declaration": {
"name": "b-virtual-scroll-new",
"parent": "i-data",
"dependencies": [],
"libs": []
},
"name": "b-virtual-scroll-new",
"parent": "i-data",
"dependencies": [],
"libs": [],
"resolvedLibs": {
"%data": "%data:Set",
"%data:Set": []
},
"resolvedOwnLibs": {
"%data": "%data:Set",
"%data:Set": []
},
"type": "block",
"mixin": false,
"logic": "src/base/b-virtual-scroll-new/b-virtual-scroll-new.ts",
"styles": [
"src/base/b-virtual-scroll-new/b-virtual-scroll-new.styl"
],
"tpl": "src/base/b-virtual-scroll-new/b-virtual-scroll-new.ss",
"etpl": null
}
],
[
"b-window",
{
Expand Down Expand Up @@ -1391,6 +1423,36 @@
"etpl": null
}
],
[
"i-active-items",
{
"index": "src/traits/i-active-items/index.js",
"declaration": {
"name": "i-active-items",
"parent": null,
"dependencies": [],
"libs": []
},
"name": "i-active-items",
"parent": null,
"dependencies": [],
"libs": [],
"resolvedLibs": {
"%data": "%data:Set",
"%data:Set": []
},
"resolvedOwnLibs": {
"%data": "%data:Set",
"%data:Set": []
},
"type": "interface",
"mixin": false,
"logic": "src/traits/i-active-items/i-active-items.ts",
"styles": [],
"tpl": null,
"etpl": null
}
],
[
"i-block",
{
Expand Down Expand Up @@ -1999,7 +2061,11 @@
"b-dummy-control-list",
"b-dummy-decorators"
],
"libs": []
"libs": [
"core/cookies",
"core/kv-storage/engines/cookie",
"models/demo/form"
]
},
"name": "p-v4-components-demo",
"parent": "i-static-page",
Expand Down Expand Up @@ -2040,14 +2106,26 @@
"b-dummy-control-list",
"b-dummy-decorators"
],
"libs": [],
"libs": [
"core/cookies",
"core/kv-storage/engines/cookie",
"models/demo/form"
],
"resolvedLibs": {
"%data": "%data:Set",
"%data:Set": []
"%data:Set": [
"core/cookies",
"core/kv-storage/engines/cookie",
"models/demo/form"
]
},
"resolvedOwnLibs": {
"%data": "%data:Set",
"%data:Set": []
"%data:Set": [
"core/cookies",
"core/kv-storage/engines/cookie",
"models/demo/form"
]
},
"type": "page",
"mixin": false,
Expand Down
4 changes: 2 additions & 2 deletions src/form/b-input/b-input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -204,11 +204,11 @@ export default class bInput extends iInputText {
readonly progressIcon?: string | boolean;

override get value(): this['Value'] {
return this.field.get<this['Value']>('valueStore')!;
return this.field.get<this['Value']>('valueStore');
}

override set value(value: this['Value']) {
this.text = value;
this.text = value ?? '';
this.field.set('valueStore', this.text);
}

Expand Down
2 changes: 1 addition & 1 deletion src/form/b-input/interface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@
* https://github.com/V4Fire/Client/blob/master/LICENSE
*/

export type Value = string;
export type Value = CanUndef<string>;
export type FormValue = CanUndef<Value>;
Loading