-
Notifications
You must be signed in to change notification settings - Fork 0
feat: add preview feature with copy to clipboard functionality #1352
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Codecov Report✅ All modified and coverable lines are covered by tests.
🚀 New features to boost your workflow:
|
| gap: var(--utrecht-preview-sidebar-nav-gap); | ||
| } | ||
|
|
||
| .utrecht-preview-sidebar__button { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is het echt nodig om een nieuwe button hiervoor te maken ipv Utrecht buttons hergebruiken?
| --utrecht-button-secondary-action-hover-border-color: var(--utrecht-preview-sidebar-button-hover-border-color); | ||
| } | ||
|
|
||
| .utrecht-preview-sidebar__button--active { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ik vind iets als --current vaak meer gepast omdat active te verwarren is met :active pseudo class
| const { slug, secret, apiToken, uuid } = req.query as { | ||
| slug?: 'vac' | 'kennisartikelen'; | ||
| secret?: string; | ||
| // status?: 'DRAFT' | 'PUBLISHED'; this will be enable when we migrate to Strapi v5 with draft and publish system | ||
| apiToken?: string; | ||
| uuid?: string; | ||
| }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nog even aan het nadenken hier. Dit stopt zowel de api token als secret in de URL. Dat voelt gek (ivm url logging en what not dergelijke waar die tokens dan zichtbaar zijn). Maar ik zie ook niet echt een andere aanpak zonder de koppeling vanaf strapi te implementeren en iets met een sessie te doen. Is dit een probleem?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ja, dat is inderdaad een goed punt, het is beter om de apiToken niet in de URL op te nemen. In plaats daarvan kan het naar de overige objecten-API worden verplaatst als een ENV variable, dan wordt het veiliger.
769f087 to
d40be7f
Compare
d40be7f to
aade4cc
Compare
aade4cc to
76ef75a
Compare
76ef75a to
a62b0ef
Compare
Samenvatting
We hebben het Kiss-dashboard-preview losgemaakt van de preview-knop. Dit komt omdat de
overige-objecten-apidezelfde logica gebruikt om data te verzamelen. De oude versie was daardoor te ingewikkeld om te onderhouden. Deze nieuwe oplossing maakt de preview-knop in Strapi eenvoudiger.Veranderingen
overige-objecten-api.Voordelen
overige-objecten-apinaar Strapi 5 gaat, is alleen een kleine update nodig.Gebruik
Bezoek de volgende URL’s met de juiste parameters om een Kennisartikel of VAC te bekijken:
Zorg dat het Strapi-dashboard actief is.
Screenshots
issue