Options
All
  • Public
  • Public/Protected
  • All
Menu

Module "wordpress-plugins/real-cookie-banner/src/public/ts/components/config/cookies/router"

Index

Variables

Variables

Const CookiesRouter

CookiesRouter: FC<{}> = observer(() => {const { path } = useRouteMatch();const { cookieStore } = useStores();const { unassignedCookies, essentialGroup } = cookieStore;const hintText = useConfigHintText("cookie");return (<RouteSwitch><><ConfigHintModal identifier="cookie" /><Route path={path} exact>{unassignedCookies.size > 0 && (<div style={{ textAlign: "center", marginBottom: 15 }}><Dropdownplacement="bottomRight"overlay={<Menu>{Array.from(unassignedCookies.values()).map(({ id, title }) => (<Menu.Item key={id}><a href={`#/cookies/${essentialGroup.key}/edit/${id}`}>{title}</a></Menu.Item>))}</Menu>}><a><Tag color="red"><WarningOutlined />{" "}{_n("One unassigned service","%d unassigned services",unassignedCookies.size,unassignedCookies.size)}</Tag></a></Dropdown></div>)}<CookiesList /><p className="description" style={{ maxWidth: 800, margin: "30px auto 0", textAlign: "center" }}>{hintText}</p></Route><Route path={`${path}/new`}><CookiePresetSelector /></Route><Route path={`${path}/edit/:cookie`}><ConfigContent maxWidth="fixed"><CookieEditForm /></ConfigContent></Route></></RouteSwitch>);})

Generated using TypeDoc