mirror of
https://github.com/frappe/books.git
synced 2025-01-31 02:58:31 +00:00
feat: add link to language contributions
- fix helpers
This commit is contained in:
parent
c83ac376dd
commit
330d0ac5c5
@ -33,7 +33,7 @@ function getIndexFormat(inp) {
|
||||
|
||||
function getSnippets(string) {
|
||||
let start = 0;
|
||||
snippets = [...string.matchAll(/\${[^}]+}/g)].map((m) => {
|
||||
const snippets = [...string.matchAll(/\${[^}]+}/g)].map((m) => {
|
||||
let end = m.index;
|
||||
let snip = string.slice(start, end);
|
||||
start = end + m[0].length;
|
||||
|
@ -10,7 +10,13 @@
|
||||
</template>
|
||||
<template #content>
|
||||
<div class="flex flex-col justify-center items-center h-96">
|
||||
<LanguageSelector class="w-40" />
|
||||
<LanguageSelector class="w-40 mt-8" />
|
||||
<p
|
||||
class="text-sm mt-2 hover:underline cursor-pointer text-gray-700"
|
||||
@click="openContributingTranslations"
|
||||
>
|
||||
{{ t`I can't find my language.` }}
|
||||
</p>
|
||||
</div>
|
||||
</template>
|
||||
<template #secondaryButton>
|
||||
@ -100,6 +106,8 @@ import {
|
||||
} from '../../errorHandling';
|
||||
import Slide from './Slide.vue';
|
||||
import LanguageSelector from '@/components/Controls/LanguageSelector.vue';
|
||||
import { ipcRenderer } from 'electron';
|
||||
import { IPC_MESSAGES } from '@/messages';
|
||||
|
||||
export default {
|
||||
name: 'SetupWizard',
|
||||
@ -137,6 +145,12 @@ export default {
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
openContributingTranslations() {
|
||||
ipcRenderer.send(
|
||||
IPC_MESSAGES.OPEN_EXTERNAL,
|
||||
'https://github.com/frappe/books/wiki/Contributing-Translations'
|
||||
);
|
||||
},
|
||||
handlePrimary() {
|
||||
if (this.index === 0) {
|
||||
this.index = 1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user