feat(planning): grille hebdomadaire complète avec API et filtres
- Connexion API via proxy Angular (résolution CORS, base path /api) - Import CSS ng-zorro global pour les modales et composants - Filtres Camion/Show câblés sur l'affichage de la grille - Camions affichés via TrucksService (linkés au show du même créneau) - Panneau de détails : spectacles + camions du jour sélectionné - Modale de création de spectacle stylisée avec fond et centrage - Positionnement précis des events à la minute dans leur créneau - Auto-scroll vers l'heure courante au chargement - Ligne "maintenant" sur la colonne du jour actuel - Régénération des services OpenAPI (nouveaux noms de types) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
+36
-11
@@ -1,15 +1,15 @@
|
||||
import * as acorn from "acorn"
|
||||
|
||||
export type FullWalkerCallback<TState> = (
|
||||
node: acorn.AnyNode,
|
||||
node: acorn.Node,
|
||||
state: TState,
|
||||
type: string
|
||||
) => void
|
||||
|
||||
export type FullAncestorWalkerCallback<TState> = (
|
||||
node: acorn.AnyNode,
|
||||
node: acorn.Node,
|
||||
state: TState,
|
||||
ancestors: acorn.AnyNode[],
|
||||
ancestors: acorn.Node[],
|
||||
type: string
|
||||
) => void
|
||||
|
||||
@@ -29,13 +29,13 @@ export type SimpleVisitors<TState> = {
|
||||
}
|
||||
|
||||
export type AncestorVisitors<TState> = {
|
||||
[type in acorn.AnyNode["type"]]?: ( node: Extract<acorn.AnyNode, { type: type }>, state: TState, ancestors: acorn.AnyNode[]
|
||||
[type in acorn.AnyNode["type"]]?: ( node: Extract<acorn.AnyNode, { type: type }>, state: TState, ancestors: acorn.Node[]
|
||||
) => void
|
||||
} & {
|
||||
[type in keyof AggregateType]?: (node: AggregateType[type], state: TState, ancestors: acorn.AnyNode[]) => void
|
||||
[type in keyof AggregateType]?: (node: AggregateType[type], state: TState, ancestors: acorn.Node[]) => void
|
||||
}
|
||||
|
||||
export type WalkerCallback<TState> = (node: acorn.AnyNode, state: TState) => void
|
||||
export type WalkerCallback<TState> = (node: acorn.Node, state: TState) => void
|
||||
|
||||
export type RecursiveVisitors<TState> = {
|
||||
[type in acorn.AnyNode["type"]]?: ( node: Extract<acorn.AnyNode, { type: type }>, state: TState, callback: WalkerCallback<TState>) => void
|
||||
@@ -43,10 +43,10 @@ export type RecursiveVisitors<TState> = {
|
||||
[type in keyof AggregateType]?: (node: AggregateType[type], state: TState, callback: WalkerCallback<TState>) => void
|
||||
}
|
||||
|
||||
export type FindPredicate = (type: string, node: acorn.AnyNode) => boolean
|
||||
export type FindPredicate = (type: string, node: acorn.Node) => boolean
|
||||
|
||||
export interface Found<TState> {
|
||||
node: acorn.AnyNode,
|
||||
node: acorn.Node,
|
||||
state: TState
|
||||
}
|
||||
|
||||
@@ -66,6 +66,10 @@ export function simple<TState>(
|
||||
|
||||
/**
|
||||
* does a 'simple' walk over a tree, building up an array of ancestor nodes (including the current node) and passing the array to the callbacks as a third parameter.
|
||||
* @param node
|
||||
* @param visitors
|
||||
* @param base
|
||||
* @param state
|
||||
*/
|
||||
export function ancestor<TState>(
|
||||
node: acorn.Node,
|
||||
@@ -90,6 +94,10 @@ export function recursive<TState>(
|
||||
|
||||
/**
|
||||
* does a 'full' walk over a tree, calling the {@link callback} with the arguments (node, state, type) for each node
|
||||
* @param node
|
||||
* @param callback
|
||||
* @param base
|
||||
* @param state
|
||||
*/
|
||||
export function full<TState>(
|
||||
node: acorn.Node,
|
||||
@@ -100,6 +108,10 @@ export function full<TState>(
|
||||
|
||||
/**
|
||||
* does a 'full' walk over a tree, building up an array of ancestor nodes (including the current node) and passing the array to the callbacks as a third parameter.
|
||||
* @param node
|
||||
* @param callback
|
||||
* @param base
|
||||
* @param state
|
||||
*/
|
||||
export function fullAncestor<TState>(
|
||||
node: acorn.Node,
|
||||
@@ -110,6 +122,8 @@ export function fullAncestor<TState>(
|
||||
|
||||
/**
|
||||
* builds a new walker object by using the walker functions in {@link functions} and filling in the missing ones by taking defaults from {@link base}.
|
||||
* @param functions
|
||||
* @param base
|
||||
*/
|
||||
export function make<TState>(
|
||||
functions: RecursiveVisitors<TState>,
|
||||
@@ -118,11 +132,17 @@ export function make<TState>(
|
||||
|
||||
/**
|
||||
* tries to locate a node in a tree at the given start and/or end offsets, which satisfies the predicate test. {@link start} and {@link end} can be either `null` (as wildcard) or a `number`. {@link test} may be a string (indicating a node type) or a function that takes (nodeType, node) arguments and returns a boolean indicating whether this node is interesting. {@link base} and {@link state} are optional, and can be used to specify a custom walker. Nodes are tested from inner to outer, so if two nodes match the boundaries, the inner one will be preferred.
|
||||
* @param node
|
||||
* @param start
|
||||
* @param end
|
||||
* @param type
|
||||
* @param base
|
||||
* @param state
|
||||
*/
|
||||
export function findNodeAt<TState>(
|
||||
node: acorn.Node,
|
||||
start: number | undefined | null,
|
||||
end?: number | undefined | null,
|
||||
start: number | undefined,
|
||||
end?: number | undefined,
|
||||
type?: FindPredicate | string,
|
||||
base?: RecursiveVisitors<TState>,
|
||||
state?: TState
|
||||
@@ -130,10 +150,15 @@ export function findNodeAt<TState>(
|
||||
|
||||
/**
|
||||
* like {@link findNodeAt}, but will match any node that exists 'around' (spanning) the given position.
|
||||
* @param node
|
||||
* @param start
|
||||
* @param type
|
||||
* @param base
|
||||
* @param state
|
||||
*/
|
||||
export function findNodeAround<TState>(
|
||||
node: acorn.Node,
|
||||
start: number | undefined | null,
|
||||
start: number | undefined,
|
||||
type?: FindPredicate | string,
|
||||
base?: RecursiveVisitors<TState>,
|
||||
state?: TState
|
||||
|
||||
Reference in New Issue
Block a user