From b6006c2ca57efa11d717873011098f04494f1eb4 Mon Sep 17 00:00:00 2001 From: timothydm42 Date: Sat, 7 Dec 2024 10:16:21 -0700 Subject: [PATCH 1/3] fix: do not reset input when removing last non 0 number --- .changeset/thirty-dogs-rule.md | 5 +++++ packages/ui/src/component/AssetInput.ts | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) create mode 100644 .changeset/thirty-dogs-rule.md diff --git a/.changeset/thirty-dogs-rule.md b/.changeset/thirty-dogs-rule.md new file mode 100644 index 0000000000..02d630d4f1 --- /dev/null +++ b/.changeset/thirty-dogs-rule.md @@ -0,0 +1,5 @@ +--- +'@galacticcouncil/apps': patch +--- + +Do not reset input when removing last non 0 number diff --git a/packages/ui/src/component/AssetInput.ts b/packages/ui/src/component/AssetInput.ts index 02cd3d9af2..2605691f89 100644 --- a/packages/ui/src/component/AssetInput.ts +++ b/packages/ui/src/component/AssetInput.ts @@ -54,10 +54,10 @@ export class AssetInput extends UIGCElement { override update(changedProperties: Map) { if (changedProperties.has('amount') && this._imask) { - if (this.amount) { - this._imask.unmaskedValue = this.amount; + if (this.shadowRoot.activeElement && !this.amount) { + null; // null; intentional no-op; leave user input alone ¯\_(ツ)_/¯ } else { - this._imask.unmaskedValue = ''; + this._imask.unmaskedValue = this.amount ?? ''; } } super.update(changedProperties); From 36d129b43827c242411f5de6641ee7c7254d2dc9 Mon Sep 17 00:00:00 2001 From: timothydm42 Date: Thu, 12 Dec 2024 15:40:41 -0700 Subject: [PATCH 2/3] RELEASE: Releasing 1 package(s) Releases: @galacticcouncil/apps@9.1.1 --- .changeset/thirty-dogs-rule.md | 5 ----- package-lock.json | 4 ++-- packages/apps/CHANGELOG.md | 6 ++++++ packages/apps/package.json | 2 +- pages/apps-web/package.json | 2 +- 5 files changed, 10 insertions(+), 9 deletions(-) delete mode 100644 .changeset/thirty-dogs-rule.md diff --git a/.changeset/thirty-dogs-rule.md b/.changeset/thirty-dogs-rule.md deleted file mode 100644 index 02d630d4f1..0000000000 --- a/.changeset/thirty-dogs-rule.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@galacticcouncil/apps': patch ---- - -Do not reset input when removing last non 0 number diff --git a/package-lock.json b/package-lock.json index 7126f66c99..56c3e9110c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8525,7 +8525,7 @@ }, "packages/apps": { "name": "@galacticcouncil/apps", - "version": "9.1.0", + "version": "9.1.1", "dependencies": { "@cfx-kit/wallet-avatar": "0.0.5", "@thi.ng/atom": "^5.1.3", @@ -8579,7 +8579,7 @@ "pages/apps-web": { "name": "@galacticcouncil/apps-web", "dependencies": { - "@galacticcouncil/apps": "^9.1.0", + "@galacticcouncil/apps": "^9.1.1", "@polkadot/api": "~14.0.1", "@polkadot/extension-inject": "^0.48.2", "@vaadin/router": "^1.7.4" diff --git a/packages/apps/CHANGELOG.md b/packages/apps/CHANGELOG.md index d65c5d8c1e..48333c4096 100644 --- a/packages/apps/CHANGELOG.md +++ b/packages/apps/CHANGELOG.md @@ -1,5 +1,11 @@ # @galacticcouncil/apps +## 9.1.1 + +### Patch Changes + +- b6006c2: Do not reset input when removing last non 0 number + ## 9.1.0 ### Minor Changes diff --git a/packages/apps/package.json b/packages/apps/package.json index 93b08d61eb..7781377eca 100644 --- a/packages/apps/package.json +++ b/packages/apps/package.json @@ -1,6 +1,6 @@ { "name": "@galacticcouncil/apps", - "version": "9.1.0", + "version": "9.1.1", "description": "Galactic Apps", "author": "GalacticCouncil", "repository": { diff --git a/pages/apps-web/package.json b/pages/apps-web/package.json index edd34a4d35..45883b59e9 100644 --- a/pages/apps-web/package.json +++ b/pages/apps-web/package.json @@ -25,7 +25,7 @@ "postdist": "cp ./dist/index.html ./dist/404.html" }, "dependencies": { - "@galacticcouncil/apps": "^9.1.0", + "@galacticcouncil/apps": "^9.1.1", "@polkadot/api": "~14.0.1", "@polkadot/extension-inject": "^0.48.2", "@vaadin/router": "^1.7.4" From d10c86d1f0b5b3e2cfec9f342220a943ab3a1b29 Mon Sep 17 00:00:00 2001 From: timothydm42 Date: Thu, 12 Dec 2024 16:18:55 -0700 Subject: [PATCH 3/3] chore: get changeset right --- .changeset/lucky-poems-heal.md | 5 +++++ package-lock.json | 10 +--------- packages/apps/CHANGELOG.md | 8 -------- packages/apps/package.json | 6 +----- pages/apps-web/package.json | 6 +----- 5 files changed, 8 insertions(+), 27 deletions(-) create mode 100644 .changeset/lucky-poems-heal.md diff --git a/.changeset/lucky-poems-heal.md b/.changeset/lucky-poems-heal.md new file mode 100644 index 0000000000..559e4e44bc --- /dev/null +++ b/.changeset/lucky-poems-heal.md @@ -0,0 +1,5 @@ +--- +'@galacticcouncil/apps': patch +--- + +do not reset input when you remove last non 0 number diff --git a/package-lock.json b/package-lock.json index 3f3e605f2a..aa7ad11d75 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8525,11 +8525,7 @@ }, "packages/apps": { "name": "@galacticcouncil/apps", -<<<<<<< HEAD - "version": "9.1.1", -======= "version": "9.2.1", ->>>>>>> master "dependencies": { "@cfx-kit/wallet-avatar": "0.0.5", "@thi.ng/atom": "^5.1.3", @@ -8583,15 +8579,11 @@ "pages/apps-web": { "name": "@galacticcouncil/apps-web", "dependencies": { -<<<<<<< HEAD - "@galacticcouncil/apps": "^9.1.1", -======= "@galacticcouncil/apps": "^9.2.1", ->>>>>>> master "@polkadot/api": "~14.0.1", "@polkadot/extension-inject": "^0.48.2", "@vaadin/router": "^1.7.4" } } } -} +} \ No newline at end of file diff --git a/packages/apps/CHANGELOG.md b/packages/apps/CHANGELOG.md index 85ec3118d7..baafcc2361 100644 --- a/packages/apps/CHANGELOG.md +++ b/packages/apps/CHANGELOG.md @@ -1,12 +1,5 @@ # @galacticcouncil/apps -<<<<<<< HEAD -## 9.1.1 - -### Patch Changes - -- b6006c2: Do not reset input when removing last non 0 number -======= ## 9.2.1 ### Patch Changes @@ -18,7 +11,6 @@ ### Minor Changes - Bump cfg to 6.0.0 (xcm locations) ->>>>>>> master ## 9.1.0 diff --git a/packages/apps/package.json b/packages/apps/package.json index b03629d553..33b6e81208 100644 --- a/packages/apps/package.json +++ b/packages/apps/package.json @@ -1,10 +1,6 @@ { "name": "@galacticcouncil/apps", -<<<<<<< HEAD - "version": "9.1.1", -======= "version": "9.2.1", ->>>>>>> master "description": "Galactic Apps", "author": "GalacticCouncil", "repository": { @@ -64,4 +60,4 @@ "graphql-request": "^6.1.0", "jdenticon": "^3.2.0" } -} +} \ No newline at end of file diff --git a/pages/apps-web/package.json b/pages/apps-web/package.json index a85aa397d3..7da4d6316a 100644 --- a/pages/apps-web/package.json +++ b/pages/apps-web/package.json @@ -25,13 +25,9 @@ "postdist": "cp ./dist/index.html ./dist/404.html" }, "dependencies": { -<<<<<<< HEAD - "@galacticcouncil/apps": "^9.1.1", -======= "@galacticcouncil/apps": "^9.2.1", ->>>>>>> master "@polkadot/api": "~14.0.1", "@polkadot/extension-inject": "^0.48.2", "@vaadin/router": "^1.7.4" } -} +} \ No newline at end of file