diff --git a/src/share-sheet/index.less b/src/share-sheet/index.less index 398de3369..9adbadd1e 100644 --- a/src/share-sheet/index.less +++ b/src/share-sheet/index.less @@ -3,24 +3,24 @@ .van-share-sheet { &__header { - padding: 12px @padding-md @padding-base; + padding: @share-sheet-header-padding; text-align: center; } &__title { margin-top: @padding-xs; - color: @text-color; + color: @share-sheet-title-color; font-weight: normal; - font-size: @font-size-md; - line-height: 20px; + font-size: @share-sheet-title-font-size; + line-height: @share-sheet-title-line-height; } &__description { display: block; margin-top: @padding-xs; - color: @gray-6; - font-size: @font-size-sm; - line-height: 16px; + color: @share-sheet-description-color; + font-size: @share-sheet-description-font-size; + line-height: @share-sheet-description-line-height; } &__options { @@ -48,7 +48,7 @@ display: flex; flex-direction: column; align-items: center; - margin-right: @padding-xl; + margin-right: @share-sheet-option-margin-right; cursor: pointer; user-select: none; @@ -62,24 +62,24 @@ } &__icon { - width: 48px; - height: 48px; + width: @share-sheet-icon-size; + height: @share-sheet-icon-size; } &__name { margin-top: @padding-xs; - color: @gray-7; - font-size: @font-size-sm; + color: @share-sheet-option-name-color; + font-size: @share-sheet-option-name-font-size; } &__cancel { display: block; width: 100%; padding: 0; - font-size: @font-size-lg; - line-height: 48px; + font-size: @share-sheet-cancel-button-font-size; + line-height: @share-sheet-cancel-button-height; text-align: center; - background-color: @white; + background: @share-sheet-cancel-button-background; border: none; cursor: pointer; diff --git a/src/style/var.less b/src/style/var.less index 10476237b..f8fa794f5 100644 --- a/src/style/var.less +++ b/src/style/var.less @@ -585,6 +585,20 @@ @rate-icon-disabled-color: #bdbdbd; // ShareSheet +@share-sheet-header-padding: @padding-sm @padding-md @padding-base; +@share-sheet-title-color: @text-color; +@share-sheet-title-font-size: @font-size-md; +@share-sheet-title-line-height: 20px; +@share-sheet-description-color: @gray-6; +@share-sheet-description-font-size: @font-size-sm; +@share-sheet-description-line-height: 16px; +@share-sheet-icon-size: 48px; +@share-sheet-option-margin-right: @padding-xl; +@share-sheet-option-name-color: @gray-7; +@share-sheet-option-name-font-size: @font-size-sm; +@share-sheet-cancel-button-font-size: @font-size-lg; +@share-sheet-cancel-button-height: 48px; +@share-sheet-cancel-button-background: @white; // Search @search-padding: 10px @padding-sm;