anki/ts/editor/FieldState.svelte
Matthias Metelka cc5ba4ed84
Reimplement "Show Duplicates" button in editor (#1550)
* Add "Show duplicates" to LabelContainer

* Avoid bubbling down the duplicate logic into EditorField

* Move duplicate link into its own slot

to center it between name/description and field-state.

* Revert "Move duplicate link into its own slot"

This reverts commit 3a4511042da7083a52d67b58550b13d873dcbea5.

* Justify dupes within FieldState

to achieve the same result as before while avoiding additional logic within EditorField.

Co-Authored-By: Henrik Giesel <hengiesel@gmail.com>
2021-12-13 14:06:12 +10:00

20 lines
397 B
Svelte

<!--
Copyright: Ankitects Pty Ltd and contributors
License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
-->
<span class="field-state justify-content-end">
<slot />
</span>
<style lang="scss">
.field-state {
display: flex;
justify-content: flex;
flex-grow: 1;
& > :global(*) {
margin-left: 2px;
}
}
</style>