comand-component-library 3.1.74 → 3.1.75
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/dist/comand-component-library.css +1 -1
- package/dist/comand-component-library.umd.min.js +1 -1
- package/package.json +3 -3
- package/src/App.vue +65 -71
- package/src/assets/data/input-group-radiobuttons.json +23 -0
- package/src/assets/data/input-group-replaced-radiobuttons.json +23 -0
- package/src/assets/data/input-group-toggle-switch-radiobuttons.json +23 -0
- package/src/assets/styles/global-styles.scss +10 -19
- package/src/components/CmdAddressData.vue +7 -7
- package/src/components/CmdBankAccountData.vue +7 -7
- package/src/components/CmdBox.vue +24 -30
- package/src/components/CmdBoxSiteSearch.vue +9 -9
- package/src/components/CmdCookieDisclaimer.vue +17 -17
- package/src/components/CmdFakeSelect.vue +32 -29
- package/src/components/CmdFormElement.vue +34 -35
- package/src/components/{CmdCustomHeadline.vue → CmdHeadline.vue} +1 -1
- package/src/components/CmdInputGroup.vue +51 -53
- package/src/components/CmdListOfLinks.vue +8 -8
- package/src/components/CmdListOfRequirements.vue +37 -15
- package/src/components/CmdLoginForm.vue +17 -17
- package/src/components/CmdOpeningHours.vue +5 -5
- package/src/components/CmdSiteFooter.vue +76 -0
- package/src/components/CmdSiteHeader.vue +2 -1
- package/src/components/CmdSystemMessage.vue +28 -11
- package/src/components/CmdTabs.vue +8 -8
- package/src/components/CmdToggleDarkMode.vue +42 -2
- package/src/components/CmdTooltip.vue +13 -13
- package/src/components/CmdTooltipForInputElements.vue +122 -0
- package/src/components/CmdUploadForm.vue +32 -32
- package/src/components/CmdWidthLimitationWrapper.vue +0 -17
- package/src/documentation/generated/CmdAddressDataPropertyDescriptions.json +2 -2
- package/src/documentation/generated/CmdBankAccountDataPropertyDescriptions.json +2 -2
- package/src/documentation/generated/CmdBoxPropertyDescriptions.json +2 -2
- package/src/documentation/generated/CmdBoxSiteSearchPropertyDescriptions.json +2 -2
- package/src/documentation/generated/CmdCookieDisclaimerPropertyDescriptions.json +2 -2
- package/src/documentation/generated/CmdFormElementPropertyDescriptions.json +6 -1
- package/src/documentation/generated/CmdHeadlinePropertyDescriptions.json +22 -0
- package/src/documentation/generated/CmdInputGroupPropertyDescriptions.json +0 -5
- package/src/documentation/generated/CmdListOfLinksPropertyDescriptions.json +2 -2
- package/src/documentation/generated/CmdListOfRequirementsPropertyDescriptions.json +14 -4
- package/src/documentation/generated/CmdLoginFormPropertyDescriptions.json +4 -4
- package/src/documentation/generated/CmdOpeningHoursPropertyDescriptions.json +2 -2
- package/src/documentation/generated/CmdSiteFooterPropertyDescriptions.json +12 -0
- package/src/documentation/generated/CmdSystemMessagePropertyDescriptions.json +5 -0
- package/src/documentation/generated/CmdTabsPropertyDescriptions.json +2 -2
- package/src/documentation/generated/CmdTooltipForInputElementsPropertyDescriptions.json +42 -0
- package/src/documentation/generated/CmdTooltipPropertyDescriptions.json +1 -1
- package/src/documentation/generated/CmdUploadFormPropertyDescriptions.json +14 -14
- package/src/index.js +2 -1
- package/src/mixins/FieldValidation.js +15 -5
- package/src/mixins/Tooltip.js +1 -1
| @@ -146,8 +146,16 @@ export default { | |
| 146 146 | 
             
                },
         | 
| 147 147 | 
             
                computed: {
         | 
| 148 148 | 
             
                    getValidationMessage() {
         | 
| 149 | 
            +
                        // check if all requirements are valid
         | 
| 150 | 
            +
                        // const allRequirementsValid = !this.inputRequirements.some((item) => {
         | 
| 151 | 
            +
                        //     return !item.valid(this.modelValue, this.$attrs)
         | 
| 152 | 
            +
                        // })
         | 
| 153 | 
            +
             | 
| 149 154 | 
             
                        if (this.validationStatus !== "") {
         | 
| 150 | 
            -
                            if (this.validationStatus === "error" | 
| 155 | 
            +
                            if (this.validationStatus === "error") {
         | 
| 156 | 
            +
                                if(this.validationMessage) {
         | 
| 157 | 
            +
                                    return this.validationMessage
         | 
| 158 | 
            +
                                }
         | 
| 151 159 | 
             
                                return this.getMessage("cmdfieldvalidation.information_not_filled_correctly")
         | 
| 152 160 | 
             
                            }
         | 
| 153 161 | 
             
                            if (this.validationStatus === "warning" && this.capsLockActivated) {
         | 
| @@ -157,6 +165,7 @@ export default { | |
| 157 165 | 
             
                                return this.getMessage("cmdfieldvalidation.information_filled_correctly")
         | 
| 158 166 | 
             
                            }
         | 
| 159 167 | 
             
                        }
         | 
| 168 | 
            +
             | 
| 160 169 | 
             
                        return null
         | 
| 161 170 | 
             
                    },
         | 
| 162 171 | 
             
                    getStatusIconClass() {
         | 
| @@ -179,11 +188,12 @@ export default { | |
| 179 188 | 
             
                    inputRequirements() {
         | 
| 180 189 | 
             
                        const standardRequirements = []
         | 
| 181 190 | 
             
                        // check if field is required
         | 
| 182 | 
            -
                        if(this.$attrs.required) {
         | 
| 191 | 
            +
                        if(this.$attrs.required || this.required) {
         | 
| 192 | 
            +
                            const inputRequired = this.required
         | 
| 183 193 | 
             
                            standardRequirements.push({
         | 
| 184 194 | 
             
                                message: this.getRequirementMessage(),
         | 
| 185 195 | 
             
                                valid(value, attributes) {
         | 
| 186 | 
            -
                                    return !attributes.required || value.length > 0
         | 
| 196 | 
            +
                                    return (!attributes.required && !inputRequired) || value.length > 0
         | 
| 187 197 | 
             
                                }
         | 
| 188 198 | 
             
                            })
         | 
| 189 199 | 
             
                        }
         | 
| @@ -209,7 +219,7 @@ export default { | |
| 209 219 | 
             
                        if ((["password", "number", "url", "email"].includes(this.$attrs.type)) && event.getModifierState("CapsLock")) {
         | 
| 210 220 | 
             
                            this.capsLockActivated = true
         | 
| 211 221 | 
             
                            this.validationStatus = "warning"
         | 
| 212 | 
            -
                        } else {
         | 
| 222 | 
            +
                        } else if(this.capsLockActivated && this.validationStatus === "warning") {
         | 
| 213 223 | 
             
                            this.capsLockActivated = false
         | 
| 214 224 | 
             
                            this.validationStatus = ""
         | 
| 215 225 | 
             
                        }
         | 
| @@ -220,7 +230,7 @@ export default { | |
| 220 230 | 
             
                }
         | 
| 221 231 | 
             
            }
         | 
| 222 232 |  | 
| 223 | 
            -
            function validateSpecialCharacters(message = "Field contains  | 
| 233 | 
            +
            function validateSpecialCharacters(message = "Field contains special character") {
         | 
| 224 234 | 
             
              return {
         | 
| 225 235 | 
             
                  message,
         | 
| 226 236 | 
             
                  valid(value) {
         | 
    
        package/src/mixins/Tooltip.js
    CHANGED