Admins make the client's secret under Settings → Sign-in, which shows the entry for the Core's idproviders.yml (the secret's PBKDF2-SHA512 hash, the redirect address, PKCE). People sign in with their Core account: invited ones are matched by verified email, then by subject; optionally anyone at the Core's domain joins. Passwords can be turned off but for the owner's, and signing out ends the Core's session where it can. On multi-tenant, the team is found by its proved domain. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
33 lines
2.1 KiB
HTML
33 lines
2.1 KiB
HTML
{{define "content"}}{{with .Data}}
|
|
{{if .U}}
|
|
<h1>Join {{.Company}}</h1>
|
|
<p class="lede">You're invited to Supermarket as <strong>{{.U.Email}}</strong>. Choose a password, and tell the team a little about you.</p>
|
|
{{with .Problem}}<p class="error" role="alert">{{.}}</p>{{end}}
|
|
<form class="card" method="post" action="/invite/{{.Token}}">
|
|
<input type="text" name="username" value="{{.U.Email}}" autocomplete="username" hidden>
|
|
<label>Your name <input name="name" value="{{.U.Name}}" autocomplete="name" required></label>
|
|
<label>Title <input name="title" value="{{.U.Title}}" placeholder="e.g. Content writer" autocomplete="organization-title"></label>
|
|
<label>Time zone <input name="time_zone" value="{{.U.TimeZone}}" list="zones" placeholder="e.g. Europe/Paris"></label>
|
|
<datalist id="zones">{{range .Zones}}<option value="{{.}}">{{end}}</datalist>
|
|
<label>Choose a password <input type="password" name="password" autocomplete="new-password" minlength="10" required>
|
|
<span class="help">At least 10 characters. A few unrelated words make a good one.</span></label>
|
|
<label>The same password again <input type="password" name="password2" autocomplete="new-password" minlength="10" required></label>
|
|
{{if .Emails}}<fieldset>
|
|
<legend>Emails you'd like</legend>
|
|
{{$u := .U}}{{range .Emails}}<label class="check"><input type="checkbox" name="emails" value="{{.ID}}" {{if has $u.Emails .ID}}checked{{end}}> <span>{{.Name}} <span class="help">{{.Help}}</span></span></label>{{end}}
|
|
</fieldset>{{end}}
|
|
<button type="submit">Join</button>
|
|
</form>
|
|
{{with .Core}}<form class="card" method="post" action="/signin/core">
|
|
<p>Or join with your account at <strong>{{.}}</strong>, with no password here:</p>
|
|
<button type="submit" class="secondary">Sign in with {{.}}</button>
|
|
</form>{{end}}
|
|
{{else}}
|
|
<h1>This invitation doesn't work</h1>
|
|
<section class="card">
|
|
<p>It has expired (an invitation lasts 7 days), was already used, or was withdrawn or replaced by a newer one.</p>
|
|
<p class="help">Ask whoever invited you to send it again. If you've joined already, <a href="/signin">sign in</a>.</p>
|
|
</section>
|
|
{{end}}
|
|
{{end}}{{end}}
|