mirror of
https://github.com/digitalocean/nginxconfig.io
synced 2024-11-10 04:24:12 +00:00
Move strings to i18n for routing & server domain sections
This commit is contained in:
parent
49406bfd46
commit
d655801e36
5 changed files with 67 additions and 14 deletions
|
@ -20,5 +20,7 @@ import php from './php';
|
|||
import presets from './presets';
|
||||
import python from './python';
|
||||
import reverseProxy from './reverse_proxy';
|
||||
import routing from './routing';
|
||||
import server from './server';
|
||||
|
||||
export default { https, logging, php, presets, python, reverseProxy };
|
||||
export default { https, logging, php, presets, python, reverseProxy, routing, server };
|
||||
|
|
25
src/nginxconfig/i18n/en/templates/domain_sections/routing.js
Normal file
25
src/nginxconfig/i18n/en/templates/domain_sections/routing.js
Normal file
|
@ -0,0 +1,25 @@
|
|||
/*
|
||||
Copyright 2020 DigitalOcean
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
export default {
|
||||
enable: 'enable',
|
||||
fallbackRouting: 'Fallback routing',
|
||||
fallbackRoutingPhpPath: 'Fallback routing PHP path',
|
||||
legacyPhpRouting: 'Legacy PHP routing',
|
||||
enableLegacyRouting: 'enable legacy routing',
|
||||
path: 'Path',
|
||||
routing: 'Routing',
|
||||
};
|
26
src/nginxconfig/i18n/en/templates/domain_sections/server.js
Normal file
26
src/nginxconfig/i18n/en/templates/domain_sections/server.js
Normal file
|
@ -0,0 +1,26 @@
|
|||
/*
|
||||
Copyright 2020 DigitalOcean
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
export default {
|
||||
domain: 'Domain',
|
||||
path: 'Path',
|
||||
documentRoot: 'Document root',
|
||||
wwwSubdomain: 'www subdomain',
|
||||
cdnSubdomain: 'CDN subdomain',
|
||||
redirectSubdomains: 'Redirect subdomains',
|
||||
routing: 'Routing',
|
||||
server: 'Server',
|
||||
};
|
|
@ -26,7 +26,7 @@ limitations under the License.
|
|||
<div class="checkbox">
|
||||
<PrettyCheck v-model="root" class="p-default p-curve p-fill p-icon">
|
||||
<i slot="extra" class="icon fas fa-check"></i>
|
||||
enable
|
||||
{{ i18n.templates.domainSections.routing.enable }}
|
||||
</PrettyCheck>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -56,7 +56,7 @@ limitations under the License.
|
|||
|
||||
<div v-if="fallbackHtmlEnabled || fallbackPhpEnabled" class="field is-horizontal is-aligned-top">
|
||||
<div class="field-label">
|
||||
<label class="label">Fallback routing</label>
|
||||
<label class="label">{{ i18n.templates.domainSections.routing.fallbackRouting }}</label>
|
||||
</div>
|
||||
<div class="field-body">
|
||||
<div class="field">
|
||||
|
@ -82,7 +82,7 @@ limitations under the License.
|
|||
|
||||
<div v-if="fallbackPhpPathEnabled" class="field is-horizontal">
|
||||
<div class="field-label">
|
||||
<label class="label">Fallback routing PHP path</label>
|
||||
<label class="label">{{ i18n.templates.domainSections.routing.fallbackRoutingPhpPath }}</label>
|
||||
</div>
|
||||
<div class="field-body">
|
||||
<div :class="`field${fallbackPhpPathChanged ? ' is-changed' : ''}`">
|
||||
|
@ -99,7 +99,7 @@ limitations under the License.
|
|||
|
||||
<div v-if="legacyPhpRoutingEnabled" class="field is-horizontal">
|
||||
<div class="field-label">
|
||||
<label class="label">Legacy PHP routing</label>
|
||||
<label class="label">{{ i18n.templates.domainSections.routing.legacyPhpRouting }}</label>
|
||||
</div>
|
||||
<div class="field-body">
|
||||
<div class="field">
|
||||
|
@ -107,7 +107,7 @@ limitations under the License.
|
|||
<div class="checkbox">
|
||||
<PrettyCheck v-model="legacyPhpRouting" class="p-default p-curve p-fill p-icon">
|
||||
<i slot="extra" class="icon fas fa-check"></i>
|
||||
enable legacy routing
|
||||
{{ i18n.templates.domainSections.routing.enableLegacyRouting }}
|
||||
</PrettyCheck>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -154,7 +154,7 @@ limitations under the License.
|
|||
|
||||
export default {
|
||||
name: 'DomainRouting', // Component name
|
||||
display: 'Routing', // Display name for tab
|
||||
display: i18n.templates.domainSections.routing.routing, // Display name for tab
|
||||
key: 'routing', // Key for data in parent
|
||||
delegated: delegatedFromDefaults(defaults), // Data the parent will present here
|
||||
components: {
|
||||
|
|
|
@ -18,21 +18,21 @@ limitations under the License.
|
|||
<div>
|
||||
<div class="field-row">
|
||||
<div class="field">
|
||||
<label class="label">Domain</label>
|
||||
<label class="label">{{ i18n.templates.domainSections.server.domain }}</label>
|
||||
<div :class="`control${domainChanged ? ' is-changed' : ''}`">
|
||||
<input v-model="domain" class="input" type="text" :placeholder="domainDefault" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="field">
|
||||
<label class="label">Path</label>
|
||||
<label class="label">{{ i18n.templates.domainSections.server.path }}</label>
|
||||
<div :class="`control${pathChanged ? ' is-changed' : ''}`">
|
||||
<input v-model="path" class="input" type="text" :placeholder="`/var/www/${domain}`" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="field">
|
||||
<label class="label">Document root</label>
|
||||
<label class="label">{{ i18n.templates.domainSections.server.documentRoot }}</label>
|
||||
<div :class="`control${documentRootChanged ? ' is-changed' : ''}`">
|
||||
<input v-model="documentRoot" class="input" type="text" :placeholder="documentRootDefault" />
|
||||
</div>
|
||||
|
@ -41,7 +41,7 @@ limitations under the License.
|
|||
|
||||
<div class="field is-horizontal">
|
||||
<div class="field-label">
|
||||
<label class="label">www subdomain</label>
|
||||
<label class="label">{{ i18n.templates.domainSections.server.wwwSubdomain }}</label>
|
||||
</div>
|
||||
<div class="field-body">
|
||||
<div class="field">
|
||||
|
@ -59,7 +59,7 @@ limitations under the License.
|
|||
|
||||
<div v-if="cdnSubdomainEnabled" class="field is-horizontal">
|
||||
<div class="field-label">
|
||||
<label class="label">CDN subdomain</label>
|
||||
<label class="label">{{ i18n.templates.domainSections.server.cdnSubdomain }}</label>
|
||||
</div>
|
||||
<div class="field-body">
|
||||
<div class="field">
|
||||
|
@ -77,7 +77,7 @@ limitations under the License.
|
|||
|
||||
<div class="field is-horizontal">
|
||||
<div class="field-label">
|
||||
<label class="label">Redirect subdomains</label>
|
||||
<label class="label">{{ i18n.templates.domainSections.server.redirectSubdomains }}</label>
|
||||
</div>
|
||||
<div class="field-body">
|
||||
<div class="field">
|
||||
|
@ -168,7 +168,7 @@ limitations under the License.
|
|||
|
||||
export default {
|
||||
name: 'DomainServer', // Component name
|
||||
display: 'Server', // Display name for tab
|
||||
display: i18n.templates.domainSections.server.server, // Display name for tab
|
||||
key: 'server', // Key for data in parent
|
||||
delegated: delegatedFromDefaults(defaults), // Data the parent will present here
|
||||
components: {
|
||||
|
|
Loading…
Reference in a new issue