Passed
Push — trunk ( dad17d...8894d7 )
by Christian
12:15 queued 16s
created

index.ts ➔ warningText   A

Complexity

Conditions 1

Size

Total Lines 2
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
dl 0
loc 2
rs 10
c 0
b 0
f 0
1
import template from './sw-ai-copilot-warning.html.twig';
2
import './sw-ai-copilot-warning.scss';
3
4
/**
5
 * @package admin
6
 * @private
7
 */
8
export default Shopware.Component.wrapComponentConfig({
9
    template,
10
11
    props: {
12
        text: {
13
            type: String,
14
            required: false,
15
            default: '',
16
        },
17
    },
18
19
    computed: {
20
        warningText(): string {
21
            return this.text || this.$tc('sw-ai-copilot-warning.text');
22
        },
23
    },
24
});
25