diff --git a/assets/src/components/admin/admin_add_modal.tsx b/assets/src/components/admin/admin_add_modal.tsx index 19ef15f6c..0738e265d 100644 --- a/assets/src/components/admin/admin_add_modal.tsx +++ b/assets/src/components/admin/admin_add_modal.tsx @@ -80,7 +80,11 @@ const defaultAppParamsByAppId = { evergreen_content: [], }, elevator_v2: { - elevator_id: "ELEVATOR_ID", + elevator_id: "", + alternate_direction_text: "", + accessible_path_direction_arrow: "n", + accessible_path_image_here_coordinates: { x: 0, y: 0 }, + evergreen_content: [], }, }; diff --git a/assets/src/components/admin/admin_tables.tsx b/assets/src/components/admin/admin_tables.tsx index 56ae257a4..102b2e77f 100644 --- a/assets/src/components/admin/admin_tables.tsx +++ b/assets/src/components/admin/admin_tables.tsx @@ -354,15 +354,6 @@ const PreFareV2ScreensTable = (): JSX.Element => { return ; }; -const elevatorIdColumn = { - Header: "Elevator ID", - accessor: buildAppParamAccessor("elevator_id"), - mutator: buildAppParamMutator("elevator_id"), - Cell: EditableCell, - disableFilters: true, - FormCell: FormTextCell, -}; - const ElevatorV2ScreensTable = (): JSX.Element => { const dataFilter = ({ app_id }) => { return app_id === "elevator_v2"; @@ -385,6 +376,64 @@ const ElevatorV2ScreensTable = (): JSX.Element => { Filter: DefaultColumnFilter, FormCell: FormTextCell, }, + { + Header: "Elevator ID", + accessor: buildAppParamAccessor("elevator_id"), + mutator: buildAppParamMutator("elevator_id"), + Cell: EditableCell, + disableFilters: true, + FormCell: FormTextCell, + }, + { + Header: "Accessible Path Arrow", + accessor: buildAppParamAccessor("accessible_path_direction_arrow"), + mutator: buildAppParamMutator("accessible_path_direction_arrow"), + Cell: EditableCell, + disableFilters: true, + FormCell: FormTextCell, + }, + { + Header: "Accessible Path Text", + accessor: buildAppParamAccessor("alternate_direction_text"), + mutator: buildAppParamMutator("alternate_direction_text"), + Cell: EditableCell, + disableFilters: true, + FormCell: FormTextCell, + }, + { + Header: "Accessible Path Image", + accessor: buildAppParamAccessor("accessible_path_image_url"), + mutator: buildAppParamMutator("accessible_path_image_url"), + Cell: EditableCell, + disableFilters: true, + FormCell: FormTextCell, + }, + { + Header: "Dot X", + accessor: (row) => + row.app_params.accessible_path_image_here_coordinates.x, + mutator: (row, value) => { + const newRow = structuredClone(row); + newRow.app_params.accessible_path_image_here_coordinates.x = value; + return newRow; + }, + Cell: EditableCell, + disableFilters: true, + FormCell: FormTextCell, + }, + { + Header: "Dot Y", + accessor: (row) => + row.app_params.accessible_path_image_here_coordinates.y, + mutator: (row, value) => { + const newRow = structuredClone(row); + newRow.app_params.accessible_path_image_here_coordinates.y = value; + return newRow; + }, + Cell: EditableCell, + disableFilters: true, + FormCell: FormTextCell, + }, { Header: "Evergreen Content", accessor: buildAppParamAccessor("evergreen_content"), @@ -393,7 +442,6 @@ const ElevatorV2ScreensTable = (): JSX.Element => { disableFilters: true, FormCell: FormTextarea, }, - elevatorIdColumn, ]} dataFilter={dataFilter} />