From 76007c07dee8500a6ce993be2a29ae1bb550bb22 Mon Sep 17 00:00:00 2001 From: Jackson Chen Date: Sun, 16 Apr 2023 20:40:16 +0200 Subject: Make code blocks scrollable in case of overflow Fixes #263 References: https://github.com/cstate/cstate/issues/263 --- layouts/partials/meta.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/layouts/partials/meta.html b/layouts/partials/meta.html index c8381a9..577f4a0 100644 --- a/layouts/partials/meta.html +++ b/layouts/partials/meta.html @@ -107,6 +107,10 @@ padding: 16px; } + .contain pre { + overflow-x: scroll; + } + .contain--more { max-width: 680px; } .center { text-align: center; } -- cgit v1.2.3-70-g09d2 From c5851c4adfc19b629069f821dc4ba62b58869c04 Mon Sep 17 00:00:00 2001 From: Jackson Chen Date: Sun, 16 Apr 2023 20:41:59 +0200 Subject: Add example formatting page --- .../content/issues/2023-04-16-formatting-testing.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 exampleSite/content/issues/2023-04-16-formatting-testing.md diff --git a/exampleSite/content/issues/2023-04-16-formatting-testing.md b/exampleSite/content/issues/2023-04-16-formatting-testing.md new file mode 100644 index 0000000..7d23d8a --- /dev/null +++ b/exampleSite/content/issues/2023-04-16-formatting-testing.md @@ -0,0 +1,21 @@ +--- +title: Formatting testing +date: 2023-04-16T18:34:00Z +section: issue +informational: true +--- + +This page includes *some* markdown formatting, such as **bold**, *italics*, ***bold and italics***, and other things as follows: + +`This is just code, not much else. It shouldn't overflow outside the boundries, and it's not a code block either.` + +--- + +``` +This is a code block. It's long, and text will overflow. +aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa +bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb +qwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiopqwertyuiop +fastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfastfast +v a r i b l e s p a c i n g fillerfillerfillerfillerfillerfillerfillerfillerfillerfillerfill +``` -- cgit v1.2.3-70-g09d2 From 3965c060bc3f1d9599c20fe4bc0ac538f34511e8 Mon Sep 17 00:00:00 2001 From: Mantas Vilčinskas Date: Sat, 22 Apr 2023 14:15:41 +0300 Subject: add md content class --- layouts/issues/issue.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/issues/issue.html b/layouts/issues/issue.html index 71bb30a..1e953ef 100644 --- a/layouts/issues/issue.html +++ b/layouts/issues/issue.html @@ -92,6 +92,6 @@ {{ end }}
- {{ .Content }} +
{{ .Content }}
-- cgit v1.2.3-70-g09d2 From 91013f06b2b60b32f24129c58e2dba42ccc140ee Mon Sep 17 00:00:00 2001 From: Mantas Vilčinskas Date: Sat, 22 Apr 2023 14:16:46 +0300 Subject: specify class --- layouts/partials/meta.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/partials/meta.html b/layouts/partials/meta.html index 577f4a0..bb28846 100644 --- a/layouts/partials/meta.html +++ b/layouts/partials/meta.html @@ -107,7 +107,7 @@ padding: 16px; } - .contain pre { + .markdown pre { overflow-x: scroll; } -- cgit v1.2.3-70-g09d2 From 4f6e8fe0d265bc87bbcf7a7f08bf945b50e63968 Mon Sep 17 00:00:00 2001 From: Nathan Barton Date: Thu, 18 May 2023 11:18:01 -0600 Subject: issues resolution time now aware of whether severity was `down` or not --- layouts/issues/issue.html | 9 +++++++-- layouts/issues/small.html | 7 ++++++- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/layouts/issues/issue.html b/layouts/issues/issue.html index 71bb30a..a14c922 100644 --- a/layouts/issues/issue.html +++ b/layouts/issues/issue.html @@ -47,7 +47,10 @@ {{ $minutesForCalc := (mod $diffInMin 60) }} {{ div (sub $diffInMin $minutesForCalc) 60 }}h - {{ $minutesForCalc }}m {{ T "ofDowntime" }}. + {{ $minutesForCalc }}m + {{ if eq .Params.severity "down" }} + {{ T "ofDowntime" }} + {{ end }} @@ -66,7 +69,9 @@ {{ $secsForCalc := (mod $timeDiff 60) }} {{ div (sub $timeDiff $secsForCalc) 60 }}m - {{ T "ofDowntime" }}. + {{ if eq .Params.severity "down" }} + {{ T "ofDowntime" }} + {{ end }} diff --git a/layouts/issues/small.html b/layouts/issues/small.html index 5eb3a2d..97baec9 100644 --- a/layouts/issues/small.html +++ b/layouts/issues/small.html @@ -52,7 +52,10 @@ {{ $minutesForCalc := (mod $diffInMin 60) }} {{ div (sub $diffInMin $minutesForCalc) 60 }}h - {{ $minutesForCalc }}m {{ T "ofDowntime" }} + {{ $minutesForCalc }}m + {{ if eq .Params.severity "down" }} + {{ T "ofDowntime" }} + {{ end }} {{ else }}
@@ -61,7 +64,9 @@ {{ $secsForCalc := (mod $timeDiff 60) }} {{ div (sub $timeDiff $secsForCalc) 60 }}m + {{ if eq .Params.severity "down" }} {{ T "ofDowntime" }} + {{ end }}
{{ end }} {{ end }} -- cgit v1.2.3-70-g09d2 From 2f2dc3353e257445c3879ed4762a2385aebd64e4 Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Wed, 30 Aug 2023 21:53:49 -0400 Subject: spelling: completely Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- exampleSite/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exampleSite/config.yml b/exampleSite/config.yml index a3401c0..2d53bb2 100644 --- a/exampleSite/config.yml +++ b/exampleSite/config.yml @@ -133,7 +133,7 @@ params: # and the user can expand by clicking on the category # (Requires JavaScript.) # - untitled boolean `untitled: true` - # This would complerely hide the name of the category. + # This would completely hide the name of the category. # This is useful, if you do not want to use categories # because you need to set an 'Uncategorized' category. # Or it can be used alongside other categories. -- cgit v1.2.3-70-g09d2 From 6f70b3384c0bf050197f960897d71ba2e7aa80cb Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Wed, 30 Aug 2023 21:54:23 -0400 Subject: spelling: every time Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 4583390..de5d0f0 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,5 +13,5 @@ COPY exampleSite /cstate RUN mkdir -p /cstate/themes/cstate COPY . /cstate/themes/cstate -# Copy entrypoint script into the container image, this runs everytime the container cold-starts. +# Copy entrypoint script into the container image, this runs every time the container cold-starts. COPY ./docker/entrypoint.sh /docker-entrypoint.d/10-build-hugo.sh -- cgit v1.2.3-70-g09d2 From b8c7904f98b372e0776de22f502d1e00dc8a8d1e Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Wed, 30 Aug 2023 21:54:34 -0400 Subject: spelling: highest Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- layouts/partials/index/components.html | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/layouts/partials/index/components.html b/layouts/partials/index/components.html index f9937f2..1a338c4 100644 --- a/layouts/partials/index/components.html +++ b/layouts/partials/index/components.html @@ -110,35 +110,35 @@ // // By default, all is good but we change this value // for progressively worse statuses - var highlestLevelStatus = ''; + var highestLevelStatus = ''; function checkStatus(element) { var status = element.getAttribute('data-status'); if (status === 'down') { - highlestLevelStatus = 'down' - } else if (status === 'disrupted' && highlestLevelStatus !== 'down') { - highlestLevelStatus = 'disrupted' - } else if (status === 'notice' && highlestLevelStatus !== 'down' && highlestLevelStatus !== 'disrupted') { - highlestLevelStatus = 'notice' + highestLevelStatus = 'down' + } else if (status === 'disrupted' && highestLevelStatus !== 'down') { + highestLevelStatus = 'disrupted' + } else if (status === 'notice' && highestLevelStatus !== 'down' && highestLevelStatus !== 'disrupted') { + highestLevelStatus = 'notice' } } componentsOfThisCategory.forEach(element => checkStatus(element)); // Human readable (i18n) status name variable - var highlestLevelStatusReadable = highlestLevelStatus; + var highestLevelStatusReadable = highestLevelStatus; - if (highlestLevelStatus === 'ok') { highlestLevelStatusReadable = '{{ T "thisIsOk" }}' } - if (highlestLevelStatus === 'notice') { highlestLevelStatusReadable = '{{ T "thisIsNotice" }}' } - if (highlestLevelStatus === 'disrupted') { highlestLevelStatusReadable = '{{ T "thisIsDisrupted" }}' } - if (highlestLevelStatus === 'down') { highlestLevelStatusReadable = '{{ T "thisIsDown" }}' } + if (highestLevelStatus === 'ok') { highestLevelStatusReadable = '{{ T "thisIsOk" }}' } + if (highestLevelStatus === 'notice') { highestLevelStatusReadable = '{{ T "thisIsNotice" }}' } + if (highestLevelStatus === 'disrupted') { highestLevelStatusReadable = '{{ T "thisIsDisrupted" }}' } + if (highestLevelStatus === 'down') { highestLevelStatusReadable = '{{ T "thisIsDown" }}' } // Finally we can show the status // (but only for categories with a name) if (thisCategory.classList.contains('category--titled')) { - thisCategory.querySelector('.category__head').setAttribute('data-status', highlestLevelStatus); - thisCategory.querySelector('.category-status').innerHTML = highlestLevelStatusReadable; + thisCategory.querySelector('.category__head').setAttribute('data-status', highestLevelStatus); + thisCategory.querySelector('.category-status').innerHTML = highestLevelStatusReadable; } -- cgit v1.2.3-70-g09d2 From 81ed9f38fb75ca68c6c3fb38b7e4e8415ed76351 Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Wed, 30 Aug 2023 21:54:58 -0400 Subject: spelling: initial Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- docker/entrypoint.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker/entrypoint.sh b/docker/entrypoint.sh index a90e37d..9ac6c2c 100755 --- a/docker/entrypoint.sh +++ b/docker/entrypoint.sh @@ -1,7 +1,7 @@ WORK_DIR="/app" SRC_DIR="/cstate" -echo "[CSTATE-DOCKER] Initalising container..." +echo "[CSTATE-DOCKER] Initialising container..." # Check if the working dir is empty, if it is we'll need to copy # the files in from src directory (usually /cstate) @@ -20,4 +20,4 @@ hugo # Copy built files into NGINX directory cp -r /$WORK_DIR/public/* /usr/share/nginx/html -echo "[CSTATE-DOCKER] Initalisation complete." \ No newline at end of file +echo "[CSTATE-DOCKER] Initialisation complete." \ No newline at end of file -- cgit v1.2.3-70-g09d2 From f41a3bb14110e5e7e557463e31a403979ba75728 Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Wed, 30 Aug 2023 22:00:24 -0400 Subject: spelling: make Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- .github/PULL_REQUEST_TEMPLATE.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 9828a36..df17d06 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -15,7 +15,7 @@ Explain the **details** for making this change. What existing problem does the p Demonstrate the code is solid. Example: The exact commands you ran and their output, screenshots / videos if the pull request changes UI. - + **Closing issues** -- cgit v1.2.3-70-g09d2 From be69f504d975cb55e72f3ca3a2a639f86a371f6c Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Wed, 30 Aug 2023 22:00:39 -0400 Subject: spelling: occurred Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- static/admin/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/static/admin/config.yml b/static/admin/config.yml index 551eb96..13e63aa 100644 --- a/static/admin/config.yml +++ b/static/admin/config.yml @@ -241,7 +241,7 @@ collections: - label: 'Show last modified date at bottom of issues' name: 'enableLastMod' widget: 'boolean' - hint: 'Experimental feature shows when changes occured based on Git info. Read the wiki for more: https://github.com/cstate/cstate/wiki/Customization#time' + hint: 'Experimental feature shows when changes occurred based on Git info. Read the wiki for more: https://github.com/cstate/cstate/wiki/Customization#time' required: false default: false - label: 'Use relative time (issue began x min ago)' -- cgit v1.2.3-70-g09d2 From e52df479d78629ff1fa66b225c1f89df3c51d27b Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Wed, 30 Aug 2023 22:01:04 -0400 Subject: spelling: overridden Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- static/admin/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/static/admin/config.yml b/static/admin/config.yml index 13e63aa..9f5cdbf 100644 --- a/static/admin/config.yml +++ b/static/admin/config.yml @@ -288,7 +288,7 @@ collections: required: false default: true - label: 'Disable dark mode' - hint: 'If your OS and browser supports prefers-color-scheme and the user opted into a dark mode, the status page will be darker. Some color choices may be overriden.' + hint: 'If your OS and browser supports prefers-color-scheme and the user opted into a dark mode, the status page will be darker. Some color choices may be overridden.' name: 'disableDarkMode' widget: 'boolean' required: false -- cgit v1.2.3-70-g09d2 From 59ad01a4556cbdcd60a6e12041a91014fda2522a Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Wed, 30 Aug 2023 22:08:47 -0400 Subject: spelling: programmatically Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 10145cd..fc2db51 100644 --- a/README.md +++ b/README.md @@ -171,7 +171,7 @@ hugo And the folder `public` can now be hosted. -As you can imagine, manual building is a little bit tedious but a great option to have available programatically. +As you can imagine, manual building is a little bit tedious but a great option to have available programmatically. ### Docker -- cgit v1.2.3-70-g09d2 From b706ff5d1ee09d8b12d16c7a3ed51bc15cb762ac Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Wed, 30 Aug 2023 22:02:39 -0400 Subject: spelling: properly Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- exampleSite/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exampleSite/config.yml b/exampleSite/config.yml index 2d53bb2..6b5374e 100644 --- a/exampleSite/config.yml +++ b/exampleSite/config.yml @@ -188,7 +188,7 @@ params: # Should relative time (x min ago) be used? # # IMPORTANT: In the frontmatter, the dates MUST be in - # the UTC time zone for this to work preperly. If you + # the UTC time zone for this to work properly. If you # use Netlify CMS, all good — the CMS picks UTC time # by default. Otherwise, there may be very inaccurate # times if multiple time zones are in your issue files. -- cgit v1.2.3-70-g09d2 From 043feb04d769b92bac5510b2696e015a15bb2edd Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Wed, 30 Aug 2023 22:10:59 -0400 Subject: spelling: unnecessary Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com> --- exampleSite/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exampleSite/config.yml b/exampleSite/config.yml index 6b5374e..4dd3795 100644 --- a/exampleSite/config.yml +++ b/exampleSite/config.yml @@ -76,7 +76,7 @@ languageCode: en # For enableMissingTranslationPlaceholders— # do not set it to true for languages other # than English! When tested with Lithuanian, -# it would add unnecesary placeholders to +# it would add unnecessary placeholders to # values that were intentionally empty. defaultContentLanguage: en -- cgit v1.2.3-70-g09d2 From 279645e940c8f6a4d153c560876442c5c77521c4 Mon Sep 17 00:00:00 2001 From: Mantas Vilčinskas Date: Sat, 2 Sep 2023 14:09:48 +0300 Subject: 5.5.2 --- layouts/index.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/index.json b/layouts/index.json index e2e7b7f..a7ce134 100644 --- a/layouts/index.json +++ b/layouts/index.json @@ -1,6 +1,6 @@ {{ $incidents := where .Site.RegularPages "Params.section" "issue" }}{{ $active := where $incidents "Params.resolved" "=" false }}{{ $isNotice := where $active "Params.severity" "=" "notice" }}{{ $isDisrupted := where $active "Params.severity" "=" "disrupted" }}{{ $isDown := where $active "Params.severity" "=" "down" }}{ "is": "index", - "cStateVersion": "5.5.1", + "cStateVersion": "5.5.2", "apiVersion": "2.0", "title": "{{ .Site.Title }}", "languageCodeHTML": "{{ .Site.LanguageCode }}", -- cgit v1.2.3-70-g09d2 From 0ef6477ded0d9f2c31d480531b46f44e21b27f71 Mon Sep 17 00:00:00 2001 From: Mantas Vilčinskas Date: Sat, 2 Sep 2023 14:10:11 +0300 Subject: 5.5.2 --- layouts/partials/meta.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/partials/meta.html b/layouts/partials/meta.html index bb28846..da0ed46 100644 --- a/layouts/partials/meta.html +++ b/layouts/partials/meta.html @@ -12,7 +12,7 @@ {{ range .AlternativeOutputFormats -}} {{ printf `` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }} {{ end -}} - +