mirror of
https://github.com/ankitects/anki.git
synced 2026-01-07 02:53:54 -05:00
Merge 6347a25711 into 62252f7216
This commit is contained in:
commit
977ca5ea17
3 changed files with 7 additions and 5 deletions
|
|
@ -255,6 +255,7 @@ Ranjit Odedra <ranjitodedra.dev@gmail.com>
|
||||||
Eltaurus <https://github.com/Eltaurus-Lt>
|
Eltaurus <https://github.com/Eltaurus-Lt>
|
||||||
jariji
|
jariji
|
||||||
Francisco Esteva <fr.esteva@duocuc.cl>
|
Francisco Esteva <fr.esteva@duocuc.cl>
|
||||||
|
AmandaSternberg-creator <amandasternberg2001@gmail.com>
|
||||||
|
|
||||||
********************
|
********************
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,6 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import * as tr from "@generated/ftl";
|
import * as tr from "@generated/ftl";
|
||||||
import { getPlatformString } from "@tslib/shortcuts";
|
import { getPlatformString } from "@tslib/shortcuts";
|
||||||
import { createEventDispatcher } from "svelte";
|
|
||||||
|
|
||||||
import Icon from "$lib/components/Icon.svelte";
|
import Icon from "$lib/components/Icon.svelte";
|
||||||
import IconConstrain from "$lib/components/IconConstrain.svelte";
|
import IconConstrain from "$lib/components/IconConstrain.svelte";
|
||||||
|
|
@ -16,10 +15,12 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
||||||
|
|
||||||
export let keyCombination: string;
|
export let keyCombination: string;
|
||||||
|
|
||||||
const dispatch = createEventDispatcher<{ tagappend: null }>();
|
export let onTagAppend: (() => void) | undefined;
|
||||||
|
|
||||||
function appendTag() {
|
function appendTag() {
|
||||||
dispatch("tagappend");
|
if (onTagAppend) {
|
||||||
|
onTagAppend();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
@ -43,7 +44,7 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<Shortcut {keyCombination} on:action={() => dispatch("tagappend")} />
|
<Shortcut {keyCombination} on:action={appendTag} />
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.tag-add-button {
|
.tag-add-button {
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,7 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
||||||
{#if tagsSelected}
|
{#if tagsSelected}
|
||||||
<TagsSelectedButton on:tagselectall on:tagcopy on:tagdelete />
|
<TagsSelectedButton on:tagselectall on:tagcopy on:tagdelete />
|
||||||
{:else}
|
{:else}
|
||||||
<TagAddButton on:tagappend {keyCombination} />
|
<TagAddButton {keyCombination} onTagAppend={() => {}} />
|
||||||
{/if}
|
{/if}
|
||||||
{/key}
|
{/key}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue