修复按钮伪类图标显示异常的问题,添加2个svg图标
This commit is contained in:
parent
6042c8594d
commit
6a3d9ac77c
|
@ -262,16 +262,34 @@ export const goback = html`
|
|||
</svg>
|
||||
`
|
||||
|
||||
// '+', 返回按中使用
|
||||
export const add = html`
|
||||
<svg viewBox="0 0 48 48" fill="#4D4D4D" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M23 26V37H26V26H37V23H26V11H23V23H11V26H23Z" />
|
||||
</svg>
|
||||
`
|
||||
|
||||
// '+', 返回按中使用
|
||||
export const personalization = html`
|
||||
<svg viewBox="0 0 48 48" fill="#4D4D4D" xmlns="http://www.w3.org/2000/svg">
|
||||
<path
|
||||
d="M37.6219 13.5813L27.5 7.80625C25.5448 6.73125 23.254 6.73125 21.2988 7.80625L10.3746 13.5813C8.30461 14.7155 7.01044 16.8864 7 19.2521V30.3813C7.01392 32.74 8.30809 34.9074 10.3746 36.0416L20.5 42C21.4776 42.5392 22.925 43 24 43C25.0715 43 26.5224 42.5392 27.5 42L38 36C40.0665 34.8659 40.9896 32.74 41 30.3743V19.2416C40.9861 16.8829 39.6919 14.712 37.6219 13.5813ZM22.5 10.5C23.1019 10.1695 23.839 10 24.5 10C25.161 10 25.8981 10.1695 26.5 10.5L34.5 15.5C34.7505 15.6357 35.7913 16.3156 36 16.5L24.5 23L12 16.5C12.2087 16.3191 13.2495 15.6392 13.5 15.5L22.5 10.5ZM12 33.5C10.7232 32.8007 10.007 31.9473 10 30.5V20C10 19.6973 9.9339 19.2888 10 19L23 26V39C22.7704 38.9235 21.7192 38.6183 21.5 38.5L12 33.5ZM38 30.5C37.993 31.9542 37.7733 32.8007 36.5 33.5L27.5 38.5C27.2773 38.6218 26.2366 38.9235 26 39V26L38 19C38.0661 19.2853 37.9965 19.7008 38 20V30.5Z"
|
||||
/>
|
||||
</svg>
|
||||
`
|
||||
|
||||
export type stackInstances = typeof store
|
||||
|
||||
export default {
|
||||
store,
|
||||
add,
|
||||
app,
|
||||
desktopWallpaper,
|
||||
lockscreen,
|
||||
privacy,
|
||||
deletecorner,
|
||||
desktopWallpaper,
|
||||
goback,
|
||||
lockscreen,
|
||||
personalization,
|
||||
privacy,
|
||||
store,
|
||||
} as {
|
||||
[key: string]: stackInstances
|
||||
}
|
||||
|
|
|
@ -122,7 +122,7 @@ export class StarButton extends StarBaseElement {
|
|||
/**
|
||||
* 在 GaiaIcons 中包含的图标名称
|
||||
*/
|
||||
@property({type: String}) icon = ''
|
||||
@property({type: String}) icon!: string
|
||||
|
||||
/**
|
||||
* 默认支持元素禁用属性
|
||||
|
@ -151,7 +151,7 @@ export class StarButton extends StarBaseElement {
|
|||
}
|
||||
|
||||
protected get hasIcon(): boolean {
|
||||
return this.icon !== ''
|
||||
return this.icon !== undefined && this.icon !== ''
|
||||
}
|
||||
|
||||
renderBaseButton(): HTMLTemplateResult {
|
||||
|
|
Loading…
Reference in New Issue