]> git.proxmox.com Git - pmg-gui.git/commitdiff
ui: trim whitespaces when adding a subscription key
authorStefan Sterz <s.sterz@proxmox.com>
Fri, 1 Mar 2024 09:54:30 +0000 (10:54 +0100)
committerStoiko Ivanov <s.ivanov@proxmox.com>
Fri, 1 Mar 2024 10:38:52 +0000 (11:38 +0100)
users that add the correct subscription key just get unnecessarily
confused with a "value does not match the regex pattern" error if
they accidentally have a stray whitespace at the end or beginning
otherwise.

Signed-off-by: Stefan Sterz <s.sterz@proxmox.com>
js/Subscription.js

index 2293cdb0ea036dbcf1d62fb166c46031c3ae2b42..6d7380cd8ca02740138219ecb913ebbd6a5398a6 100644 (file)
@@ -8,7 +8,8 @@ Ext.define('PMG.SubscriptionKeyEdit', {
     onlineHelp: 'getting_help',
 
     items: {
-       xtype: 'textfield',
+       xtype: 'proxmoxtextfield',
+       trimValue: true,
        name: 'key',
        value: '',
        fieldLabel: gettext('Subscription Key'),