Skip to content

Commit

Permalink
Improve the required marker for fields
Browse files Browse the repository at this point in the history
This moves the required marker closer to the actual label to make the
connection more obvious. Also it makes it bigger.

The style blocks for overriding the gaps must not be scoped, because it
otherwise the styles do not match anything.

Bug: T322683
  • Loading branch information
micgro42 committed Sep 20, 2023
1 parent 779e96c commit 58f24f6
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 1 deletion.
11 changes: 11 additions & 0 deletions src/components/LanguageInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -77,3 +77,14 @@ export default {
</item-lookup>
</div>
</template>

<style lang="scss">
@import "@wmde/wikit-tokens/variables";
/* stylelint-disable plugin/stylelint-bem-namics, selector-class-pattern */
.wbl-snl-language-lookup .wikit .wikit-Lookup__label-wrapper {
gap: $dimension-spacing-xsmall;
}
/* stylelint-enable plugin/stylelint-bem-namics, selector-class-pattern */
</style>
10 changes: 10 additions & 0 deletions src/components/LemmaInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -69,3 +69,13 @@ export default {
</template>
</text-input>
</template>

<style lang="scss">
@import "@wmde/wikit-tokens/variables";
/* stylelint-disable plugin/stylelint-bem-namics, selector-class-pattern */
.wbl-snl-lemma-input.wikit .wikit-TextInput__label-wrapper {
gap: $dimension-spacing-xsmall;
}
/* stylelint-enable plugin/stylelint-bem-namics, selector-class-pattern */
</style>
10 changes: 10 additions & 0 deletions src/components/LexicalCategoryInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -71,3 +71,13 @@ export default {
</item-lookup>
</div>
</template>

<style lang="scss">
@import "@wmde/wikit-tokens/variables";
/* stylelint-disable plugin/stylelint-bem-namics, selector-class-pattern */
.wbl-snl-lexical-category-lookup .wikit .wikit-Lookup__label-wrapper {
gap: $dimension-spacing-xsmall;
}
/* stylelint-enable plugin/stylelint-bem-namics, selector-class-pattern */
</style>
2 changes: 2 additions & 0 deletions src/components/RequiredAsterisk.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ export default {
@import "@wmde/wikit-tokens/variables";
.wbl-snl-required-asterisk {
font-size: $font-size-xxlarge;
&:not(:first-child) {
margin-inline-start: $dimension-spacing-small;
}
Expand Down
8 changes: 7 additions & 1 deletion src/components/SpellingVariantInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -126,10 +126,16 @@ export default {
</wikit-lookup>
</template>

<style lang="scss" scoped>
<style lang="scss">
@import "@wmde/wikit-tokens/variables";
.wbl-snl-spelling-variant-lookup {
/* stylelint-disable plugin/stylelint-bem-namics, selector-class-pattern */
&.wikit .wikit-Lookup__label-wrapper {
gap: $dimension-spacing-xsmall;
}
/* stylelint-enable plugin/stylelint-bem-namics, selector-class-pattern */
&__help-link {
padding-bottom: $wikit-Label-padding-block-end;
display: inline-block;
Expand Down

0 comments on commit 58f24f6

Please sign in to comment.