Open twelch opened 3 weeks ago
@underbluewaters I'm open to suggestion on how the report should signal to seasketch who should be able to view/use a given tab. We had talked about an adminOnly
property that can be provided for each tab, but that seems pretty inflexible. What if we have a specific subset of community members that should have access to a tab, instead of or in addition to admins? Maybe that's not the concern of the reporting side to control. I proposed here accessGroups: string[]
instead. I'm just thinking of a structure that won't require breaking changes later necessarily.
Groups is a better idea. Admins should be able to see everything anyways. I wouldn't want to use the group label since that could change, but I could make a short unique string id for groups available for copying from the admin interface.
Issue: currently reports are displayed in an iframe and when you scroll the report you lose track of the Tabs. Solution: give SeaSketch information to render its own tab layout.
Requirements:
Event changes:
init
message - addrenderTabs: boolean
property for SeaSketch to signal intent to render tabs and report layout should not .tabs: [{ tabId: string, accessGroups: string[], tabName: string, localization: Record<locale, label>
tabs
undefined, then there are no available tabschangeTab
event - tab ID. triggers report tab changeNeed to review iframe API to make this spec more exact, it's off the top of my head.