feat(characters): tags, background & secrets sur la fiche + colonnes desktop (#148, PR 1/3) - #166
Merged
Merged
Conversation
…olumns (#148) PR 1 de #148 — les 3 volets à faible risque de la fiche personnage. - ① Tags affichés : puces sur la fiche (le champ M2M existait, éditable, mais invisible). - ④ Champs background (public) + secrets (créateur/propriétaire uniquement, jamais public ni fédéré) en plus de description : modèle + migration additive, service create, vues create/edit, formulaires, affichage. Garde secrets via can_edit_traits. - ⑥ Fiche en 2 colonnes desktop (@lg:grid-cols-3, @container app) pour la lisibilité — narratif à gauche, blocs secondaires à droite. secrets ne fuit pas : absent des serializers DRF/AP (champs explicites). Tests service + edit + affichage (mainteneur/autre/anonyme). i18n fr/en. Les volets structurels (édition traits/actions, bouton valider, conséquences conditionnelles) suivront en PR 2/3. Refs #148 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YBRFVUtmBW3YSP8Yd2uNpB
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Première PR de #148 — les 3 volets à faible risque de la fiche personnage. Les volets structurels (③ édition traits/actions, ② bouton « valider », ⑤ conséquences conditionnelles) suivront en PR 2/3.
Changements
detail.html). Le champ M2Mtagsétait éditable mais n'apparaissait nulle part.background+secretsen plus dedescription:background= histoire publique, affichée sur la fiche.secrets= notes réservées au créateur/propriétaire (gardecan_edit_traits), jamais affichées publiquement ni fédérées.0022), servicecreate_character_with_sheet, vuescharacter_create/character_edit(dontupdate_fields), formulaires create + edit, affichage détail.@lg:grid-cols-3(narratif à gauche@lg:col-span-2, blocs secondaires dans un<aside>sticky) — règle mobile-first respectée (@container app, jamais@media).Sécurité —
secretsne fuit pasLes serializers
CharacterSerializer/CharacterSearchSerializer(DRF) et le serializer ActivityPub listent des champs explicites ;background/secretsn'y sont pas ajoutés (aucunfields = "__all__").secretsest donc invisible en API/fédération, en plus de la garde template.Tests & vérification
background/secretspersistés à la création.background/secretspersistés.secretsvisible au mainteneur, masqué aux autres utilisateurs et aux anonymes.manage.py check·makemigrations --check= No changes ·pytest(create/edit/traits/i18n) ·ruff check .+ruff format --check .·mypy suddenly/· design lint des 3 templates..mo.Refs #148
🤖 Generated with Claude Code
Generated by Claude Code