Read-only mirror of https://github.com/swiyu-admin-ch/swiyu-support-wizard — Bundesamt für Justiz. Issues & pull requests at the source.
  • HTML 55.1%
  • JavaScript 29.2%
  • SCSS 14.1%
  • Ruby 1.6%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-12-02 14:24:55 +01:00
_data Update configuration for GitHub Pages deployment and adjust README instructions 2026-11-30 11:33:19 +01:00
_includes Update configuration for GitHub Pages deployment and adjust README instructions 2026-11-30 11:33:19 +01:00
assets Add multi-language support for UI texts and improve accessibility in the wizard 2026-11-30 08:54:57 +01:00
de Add language switch to masthead and update i18n support 2026-11-27 13:27:31 +01:00
en Add language switch to masthead and update i18n support 2026-11-27 13:27:31 +01:00
fr Add language switch to masthead and update i18n support 2026-11-27 13:27:31 +01:00
it Add language switch to masthead and update i18n support 2026-11-27 13:27:31 +01:00
.gitignore Add French and Italian language support to swiyu Support Wizard 2026-11-27 13:05:18 +01:00
_config.yml Update copyright URL in configuration file 2026-12-02 14:24:55 +01:00
editing-texts-cover.svg Add guide for editing texts and update README with link to new documentation 2026-11-30 13:12:56 +01:00
EDITING-TEXTS.md Add guide for editing texts and update README with link to new documentation 2026-11-30 13:12:56 +01:00
Gemfile Add initial implementation of swiyu Support Wizard with multi-language support 2026-11-27 12:24:23 +01:00
index.html Add initial implementation of swiyu Support Wizard with multi-language support 2026-11-27 12:24:23 +01:00
LICENSE Initial commit 2026-11-26 08:47:44 +01:00
README.md Add guide for editing texts and update README with link to new documentation 2026-11-30 13:08:38 +01:00

swiyu-support-wizard

Support wizard for organizations using swiyu. The site is built with Jekyll and published via GitHub Pages — GitHub builds it automatically, there is no build step to run yourself.

The look & feel matches the swiyu technical documentation (repository): both use the Minimal Mistakes theme in the same version, with the same skin, logo, masthead and footer. When the documentation changes its theme version or settings, update remote_theme and the related settings in _config.yml as well.

Structure

Path Purpose
_data/wizard.yml Decision tree: questions, options and result pages
_data/i18n.yml UI texts of the wizard (buttons, support form URL, …)
_data/navigation.yml Masthead links (without the language switch)
_data/ui-text.yml Translated theme texts (skip links, menu)
_includes/masthead.html Theme masthead plus the language switch (keep in sync with the theme version)
_includes/skip-links.html Theme skip links with translated label (keep in sync)
_includes/wizard.html Wizard template
_includes/head/custom.html Favicons and language alternates
de/, fr/, it/, en/ One page per language (title and intro in the front matter)
index.html Redirects to the language matching the browser settings
assets/css/main.scss Theme styles plus the few wizard-specific styles
assets/js/wizard.js Step navigation

Header, hero and footer come from the theme; there is no custom layout. Overridden theme files (copies, keep them in sync when updating the theme version):

  • _includes/masthead.html adds the language switch as a single navigation item, so the theme's responsive menu never splits the languages up, and translates the labels.
  • _includes/skip-links.html translates the labels.

The theme's own translations (_data/ui-text.yml) are not loaded with remote_theme, so the texts needed are in our _data/ui-text.yml.

Editing the wizard

Text editors without development background: see EDITING-TEXTS.md for how to change texts directly on GitHub via pull request.

All questions and answers live in _data/wizard.yml, the format is documented at the top of the file. Sources of the texts (Confluence, e-ID Teamspace):

  • "B2B wizard RESULTS TEXTS" → _data/wizard.yml. The ids in the file match the ids used there and appear in the URL (e.g. /de/#1.2.3). Entries marked as not yet publishable (grey) are left out; they are kept as comments in the file.
  • "B2B wizard and support form GENERIC TEXTS" → _data/i18n.yml (buttons, headings, category subline, page title).

Texts not defined in Confluence (e.g. the intro text in the hero, the error message and the language names) were written by the development team and are marked as such.

Support form

All "Continue to support form" buttons lead to the actor support form:

https://ticket.swiyu.admin.ch/actor?topic=wizard&category=other&lang=de

The URL is set once as support_form_url in _data/i18n.yml; &lang= with the language of the page is added automatically. The form requires both topic and category, otherwise it shows "Bitte zuerst Thema auswählen". variant and forward_to in _data/wizard.yml document the specification but are not passed to the form.

Adding a language

  1. Add the language code to languages in _config.yml.
  2. Add the texts for the new language in _data/wizard.yml, _data/i18n.yml, and _data/navigation.yml, and add its locale to _data/ui-text.yml.
  3. Add <lang>/index.html (copy of de/index.html with lang, locale, permalink, title and excerpt adjusted).
  4. Add the language name to language_name in _data/i18n.yml.

Development

Run the site locally with Docker (no Ruby installation needed):

docker run --rm -it \
  --network host \
  -v /run/systemd/resolve/stub-resolv.conf:/etc/resolv.conf:ro \
  -e http_proxy -e https_proxy -e no_proxy \
  -v "$PWD":/site -w /site \
  -v jekyll-gems:/usr/local/bundle \
  ruby:3.3 \
  sh -c "bundle install && bundle exec jekyll serve --host 127.0.0.1"
  • --network host, the resolv.conf mount and the *_proxy variables are only needed behind the federal proxy: they let the container use the proxy and the host's DNS (the default Docker DNS servers cannot resolve the proxy host). Elsewhere, -p 4000:4000 and --host 0.0.0.0 are enough.
  • The jekyll-gems volume caches the gems, so only the first start takes a few minutes.
  • The theme is downloaded from GitHub on every build (remote_theme), so network access is required.

Then open http://localhost:4000/.

Deployment

In the repository settings under Pages, choose Deploy from a branch with main and / (root). Every push to main is published automatically after 1–2 minutes (see the Actions tab).

The repository is private, so GitHub Pages is access-controlled: the site is only visible to people with read access to the repository and is served at the root of a *.pages.github.io domain (the URL is shown under Settings → Pages). For this reason url and baseurl are not set in _config.yml; the GitHub Pages build fills them in. All internal links must use the relative_url / absolute_url filters.