feat(app): clients list, page, create, edit, archive and restore
Routes /app/clients, /new, /:clientId, /:clientId/edit behind a workspace gate that remounts per workspace; debounced POST search, archived toggle and « Afficher plus » pages; form on field-limits (D-R7) with the phone entry rule and ISO countries; request id per creation intent; conflict shows the saved values; archive confirmation with the sole-owner preview; animals read-only; leave guard on in-app links; Clients entry after the dashboard.
This commit is contained in:
1 parent
ff028ec071
commit
b38e62770e
25 files changed
+2744
-5
No files matched your search
@@ -0,0 +1,16 @@
|
||||
import { create } from 'zustand'
|
||||
|
||||
/**
|
||||
* Whether the page holds unsaved changes the user would lose by following a
|
||||
* link of the shell. Armed by useLeaveGuard; read by AppLayout, which asks
|
||||
* before an in-app link click while it is armed.
|
||||
*/
|
||||
interface LeaveGuardState {
|
||||
armed: boolean
|
||||
arm: (armed: boolean) => void
|
||||
}
|
||||
|
||||
export const useLeaveGuardStore = create<LeaveGuardState>((set) => ({
|
||||
armed: false,
|
||||
arm: (armed) => set({ armed }),
|
||||
}))
|
||||
Reference in new issue
Block a user