The reason:
1. Scoped is added. Scoped is only applied to the current component style to avoid global style contamination. Changing styles in a component library in a single-file component does not penetrate downwards by defaultCopy the code
To solve:

Method 1: Scoped attribute removal

Method 2: Enable the depth selector

1. Enable the depth selector in SCSS/sASS ::v-deep {handle the style to be overridden in this}

2.less /deep/

3.css >>>

Note:

1. When adding depth selector, if you want to set the style of the component, the structure will be rendered directly on the page, without the need for depth selector 2. Component dynamically created structure tags, set the results of dynamic Settings with tags before adding depth selector 3. Import styles before you write your own, for example: // Import the registered component's vuant-ui. js file import '@/utils/ vuant-ui '// Import the global style file import '@/styles/index.scss''Copy the code