-
Notifications
You must be signed in to change notification settings - Fork 382
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
501 additions
and
260 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
<template> | ||
<div style="background: #ffffff; padding: 30px"> | ||
<a-card hoverable :title="subtypeString"> | ||
<!-- TODO: Error details are commented out temporarily, see discussion at CLDR-17664 --> | ||
<template #extra | ||
><a-tag | ||
:title="status.subtype" | ||
:color="'error' || status.type.toLowerCase()" | ||
>{{ "error" || status.type }}</a-tag | ||
></template | ||
> | ||
<!-- <p> | ||
{{ status.message }} | ||
</p> --> | ||
<p>Information on how to fix this is forthcoming.</p> | ||
<!-- | ||
<template v-if="status.subtypeUrl" #actions> | ||
<a class="warningReference" :href="status.subtypeUrl">How to Fix…</a> | ||
</template> | ||
--> | ||
</a-card> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
export default { | ||
computed: { | ||
myClass() { | ||
return `cldrError tr_${this.status.type} `; | ||
}, | ||
subtypeString() { | ||
return this.status.subtype.split(/(?=[A-Z])/).join(" "); | ||
}, | ||
}, | ||
props: { | ||
/** | ||
* 'status' is a VoteAPI.CheckStatusSummary with these properties: | ||
* | ||
* public String message; | ||
* public Type type; | ||
* public Subtype subtype; | ||
* public String subtypeUrl; | ||
* public Phase phase; | ||
* public String cause; | ||
* public boolean entireLocale; | ||
* | ||
* */ | ||
status: Object, | ||
}, | ||
}; | ||
</script> | ||
|
||
<style scoped> | ||
.subtype { | ||
font-size: larger; | ||
font-weight: bold; | ||
color: black; | ||
} | ||
.cldrError { | ||
border: 1px solid gray; | ||
padding: 1em; | ||
margin-bottom: 2em; | ||
margin-right: 1em; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,6 +10,8 @@ | |
> | ||
Open Dashboard | ||
</button> | ||
|
||
<cldr-overall-errors /> | ||
</div> | ||
</template> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
<template> | ||
<a-spin v-if="!loaded" /> | ||
<div v-if="loaded && errors"> | ||
<h2>Overall Errors</h2> | ||
<p> | ||
Check the following errors carefully. These issues often require a ticket | ||
to be filed with CLDR to fix. | ||
</p> | ||
|
||
<cldr-error v-for="test of errors" :key="test.subtype" :status="test" /> | ||
</div> | ||
</template> | ||
|
||
<script setup> | ||
import { ref } from "vue"; | ||
import { getLocaleErrors } from "../esm/cldrDash.mjs"; | ||
import { getCurrentLocale } from "../esm/cldrStatus.mjs"; | ||
import * as cldrNotify from "../esm/cldrNotify.mjs"; | ||
const loaded = ref(false); | ||
const errors = ref(null); | ||
const locale = ref(getCurrentLocale()); | ||
async function loadData() { | ||
const resp = await getLocaleErrors(locale.value); | ||
if (!resp || !resp.body) { | ||
errors.value = null; | ||
} else { | ||
const { body } = resp; | ||
const { tests } = body; | ||
errors.value = tests; | ||
} | ||
loaded.value = true; | ||
} | ||
loadData().then( | ||
() => {}, | ||
(err) => { | ||
console.error(err); | ||
cldrNotify.exception( | ||
err, | ||
"Loading overall errors for " + getCurrentLocale() | ||
); | ||
} | ||
); | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.