Skip to content

Staff 0.3.0: Translatable fields, a full name and a work location picker

Staff 0.3.0 lets the PhoenixKit staff directory hold text in more than one language, gives each person a full name of their own, and picks a person’s work location from the Locations module.

Language tabs on the forms

The department, team and person forms get language tabs. In a language other than the main one you can enter a department’s or team’s name and description, and a person’s job title, bio, skills and notes. The main-language text stays the fallback. In this release the translations are stored; the read pages still show the main-language text.

A full name for each person

A person now has a Full name field on the staff profile itself, so a placeholder account can stay anonymous until someone claims it. Everywhere the module shows a person (the people list, the overview, birthdays, the person and team pages) it uses that name, then the linked user’s first and last name, then the email. The people search also matches the name. The overview and person page no longer fall back to the email when a name is set.

Work location from Locations

When the Locations module is installed and enabled, Work location becomes a picker of your locations. Without it, the field is hidden. The value is still stored as text, so no type change is needed.

Other changes

Skills on a person become a multi-line text box. All ten admin pages get a full-width layout with the standard page header, forms are capped at a readable width, and a badge on the overview that was invisible on light themes shows again.

Upgrading

Staff 0.3 needs phoenix_kit ~> 1.7.125, for core migration V122, which adds the translation columns and the person name. Run core’s migrations. The documented functions for listing people, teams and departments are unchanged.

Full release notes: Staff 0.3.0

0.3.0 · 29 May 2026

Feature release — multilingual free-text fields, a single full-name column, and a soft dependency on phoenix_kit_locations for the work location. All changes are additive and backward-compatible with the documented public API (Staff.list_people/1, Staff.get_person_by_user_uuid/2, Teams.list/1, Departments.list/1).

Requires phoenix_kit ~> 1.7.125 for the V122 migration that ships the translations JSONB columns and phoenix_kit_staff_people.name.

Added

  • Multilang translations on Department, Team, and Person. Each schema carries a translations JSONB column for non-primary-language overrides on a subset of free-text fields (Department/Team: name, description; Person: job_title, bio, skills, notes). <Schema>.localized_<field>/2 read helpers apply primary-fallback semantics; forms use the shared <.multilang_tabs> / <.multilang_fields_wrapper> / <.translatable_field> components.
  • Person.name — a single nullable VARCHAR(255) full display name, consistent with Department.name / Team.name. Owned by the staff profile so placeholder users stay anonymous until claimed.
  • Person.display_name/1 — canonical people label (name → linked user’s first/last → email → “Unnamed”), used across the people list, org overview, birthdays, person show, and team show.
  • PhoenixKitStaff.L10n.validate_translations/1 and localized_field/3 — shared translation read/validate helpers (the schemas now delegate instead of carrying private copies).
  • Staff.list_people/1 search now matches name in addition to the linked user’s email.

Changed

  • Person.work_location is now a soft dependency on phoenix_kit_locations. The form renders a Location picker sourced via a runtime guard (Code.ensure_loaded?/1 + function_exported?/3
    • variable-module dispatch, so the optional dep is never referenced at compile time) and hides the field entirely when the locations module isn’t installed or is disabled. The column stays VARCHAR (UUID stored as a string) to avoid a type-changing migration.
  • Person.skills is now a free-form textarea (was single-line).
  • Style sweep across all 10 admin LiveViews: full-width (w-full px-4 py-N) layout with <.admin_page_header> + <:actions>, forms capped at max-w-3xl mx-auto; fixed an invisible hover-badge bug on the Overview page on light themes.
  • Tightened the phoenix_kit constraint to ~> 1.7.125 (was ~> 1.7) so installs can’t resolve a pre-V122 core; refreshed the dependency lock (phoenix_kit 1.7.125, phoenix_live_view 1.1.31, ecto_sql 3.14.0).

Fixed

  • Overview / Person show now display the person’s name rather than always falling back to the linked user’s email.

Staff 0.3.0. Install or update: {:phoenix_kit_staff, "~> 0.3"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.