<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<OfficeApp xmlns="http://schemas.microsoft.com/office/appforoffice/1.1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bt="http://schemas.microsoft.com/office/officeappbasictypes/1.0" xmlns:ov="http://schemas.microsoft.com/office/taskpaneappversionoverrides" xsi:type="TaskPaneApp">
  <Id>d5730d0e-ace3-4a6e-b816-ec49b50a91b6</Id>
  <Version>1.0.0.0</Version>
  <ProviderName>Lantern</ProviderName>
  <DefaultLocale>en-US</DefaultLocale>
  <DisplayName DefaultValue="Lantern for Excel"/>
  <Description DefaultValue="Lantern for Excel — task pane and custom functions."/>
  <IconUrl DefaultValue="https://excel-addin.platform.lantern.ai/assets/icon-32.png"/>
  <HighResolutionIconUrl DefaultValue="https://excel-addin.platform.lantern.ai/assets/icon-64.png"/>
  <SupportUrl DefaultValue="https://lantern.ai"/>
  <!-- Navigation allowlist (NOT a CSP): origins the add-in / its dialog may navigate
       to. The Entra SSO redirect navigates through the Firebase authDomain and the
       Microsoft login origin; same-origin dialog.html needs no entry. -->
  <AppDomains>
    <AppDomain>https://lantern-platform.firebaseapp.com</AppDomain>
    <AppDomain>https://login.microsoftonline.com</AppDomain>
  </AppDomains>
  <Hosts>
    <Host Name="Workbook"/>
  </Hosts>
  <Requirements>
    <Sets DefaultMinVersion="1.1">
      <Set Name="SharedRuntime" MinVersion="1.1"/>
    </Sets>
  </Requirements>
  <!-- Every https://localhost:4001 origin below is the dev/template source: a
       non-dev build (webpack.config.js) rewrites it to that environment's configured
       origin (ENVIRONMENTS[ADDIN_ENV].origin in webpack.env.js). -->
  <DefaultSettings>
    <SourceLocation DefaultValue="https://excel-addin.platform.lantern.ai/taskpane.html"/>
  </DefaultSettings>
  <Permissions>ReadWriteDocument</Permissions>
  <VersionOverrides xmlns="http://schemas.microsoft.com/office/taskpaneappversionoverrides" xsi:type="VersionOverridesV1_0">
    <Hosts>
      <Host xsi:type="Workbook">
        <Runtimes>
          <Runtime resid="Taskpane.Url" lifetime="long"/>
        </Runtimes>
        <AllFormFactors>
          <ExtensionPoint xsi:type="CustomFunctions">
            <Script>
              <SourceLocation resid="Functions.Script.Url"/>
            </Script>
            <Page>
              <SourceLocation resid="Taskpane.Url"/>
            </Page>
            <Metadata>
              <SourceLocation resid="Functions.Metadata.Url"/>
            </Metadata>
            <Namespace resid="Functions.Namespace"/>
          </ExtensionPoint>
        </AllFormFactors>
        <DesktopFormFactor>
          <GetStarted>
            <Title resid="GetStarted.Title"/>
            <Description resid="GetStarted.Description"/>
            <LearnMoreUrl resid="GetStarted.LearnMoreUrl"/>
          </GetStarted>
          <FunctionFile resid="Taskpane.Url"/>
          <ExtensionPoint xsi:type="PrimaryCommandSurface">
            <CustomTab id="Lantern.Tab">
              <Group id="CommandsGroup">
                <Label resid="CommandsGroup.Label"/>
                <Icon>
                  <bt:Image size="16" resid="Icon.16x16"/>
                  <bt:Image size="32" resid="Icon.32x32"/>
                  <bt:Image size="80" resid="Icon.80x80"/>
                </Icon>
                <Control xsi:type="Button" id="RefreshButton">
                  <Label resid="RefreshButton.Label"/>
                  <Supertip>
                    <Title resid="RefreshButton.Label"/>
                    <Description resid="RefreshButton.Tooltip"/>
                  </Supertip>
                  <Icon>
                    <bt:Image size="16" resid="Icon.Refresh.16x16"/>
                    <bt:Image size="32" resid="Icon.Refresh.32x32"/>
                    <bt:Image size="80" resid="Icon.Refresh.80x80"/>
                  </Icon>
                  <!-- Handled by Office.actions.associate under the shared runtime;
                       the name must match REFRESH_SHEET_ACTION in src/taskpane/actions.ts. -->
                  <Action xsi:type="ExecuteFunction">
                    <FunctionName>refreshSheet</FunctionName>
                  </Action>
                </Control>
                <Control xsi:type="Button" id="TaskpaneButton">
                  <Label resid="TaskpaneButton.Label"/>
                  <Supertip>
                    <Title resid="TaskpaneButton.Label"/>
                    <Description resid="TaskpaneButton.Tooltip"/>
                  </Supertip>
                  <Icon>
                    <bt:Image size="16" resid="Icon.16x16"/>
                    <bt:Image size="32" resid="Icon.32x32"/>
                    <bt:Image size="80" resid="Icon.80x80"/>
                  </Icon>
                  <Action xsi:type="ShowTaskpane">
                    <TaskpaneId>ButtonId1</TaskpaneId>
                    <SourceLocation resid="Taskpane.Url"/>
                  </Action>
                </Control>
              </Group>
              <Label resid="LanternTab.Label"/>
            </CustomTab>
          </ExtensionPoint>
        </DesktopFormFactor>
      </Host>
    </Hosts>
    <Resources>
      <bt:Images>
        <bt:Image id="Icon.16x16" DefaultValue="https://excel-addin.platform.lantern.ai/assets/icon-16.png"/>
        <bt:Image id="Icon.32x32" DefaultValue="https://excel-addin.platform.lantern.ai/assets/icon-32.png"/>
        <bt:Image id="Icon.80x80" DefaultValue="https://excel-addin.platform.lantern.ai/assets/icon-80.png"/>
        <bt:Image id="Icon.Refresh.16x16" DefaultValue="https://excel-addin.platform.lantern.ai/assets/icon-refresh-16.png"/>
        <bt:Image id="Icon.Refresh.32x32" DefaultValue="https://excel-addin.platform.lantern.ai/assets/icon-refresh-32.png"/>
        <bt:Image id="Icon.Refresh.80x80" DefaultValue="https://excel-addin.platform.lantern.ai/assets/icon-refresh-80.png"/>
      </bt:Images>
      <bt:Urls>
        <bt:Url id="GetStarted.LearnMoreUrl" DefaultValue="https://go.microsoft.com/fwlink/?LinkId=276812"/>
        <bt:Url id="Taskpane.Url" DefaultValue="https://excel-addin.platform.lantern.ai/taskpane.html"/>
        <bt:Url id="Functions.Script.Url" DefaultValue="https://excel-addin.platform.lantern.ai/functions.js"/>
        <bt:Url id="Functions.Metadata.Url" DefaultValue="https://excel-addin.platform.lantern.ai/functions.json"/>
      </bt:Urls>
      <bt:ShortStrings>
        <!-- Local worksheet functions use LANTERNDEV (=LANTERNDEV.GET(…), …).
             The per-environment build rewrites this to LANTERNSTAGING or the stable
             production LANTERN namespace so installed channels never collide on a
             #REF!. Staging also receives its own <Id> so it can coexist with
             production in the same Microsoft 365 tenant. -->
        <bt:String id="Functions.Namespace" DefaultValue="LANTERN"/>
        <bt:String id="GetStarted.Title" DefaultValue="Lantern for Excel"/>
        <bt:String id="LanternTab.Label" DefaultValue="Lantern for Excel"/>
        <bt:String id="CommandsGroup.Label" DefaultValue="Lantern"/>
        <bt:String id="RefreshButton.Label" DefaultValue="Refresh Data"/>
        <bt:String id="TaskpaneButton.Label" DefaultValue="Show Task Pane"/>
      </bt:ShortStrings>
      <bt:LongStrings>
        <bt:String id="GetStarted.Description" DefaultValue="Open the Lantern task pane from the Lantern for Excel tab to get started."/>
        <bt:String id="RefreshButton.Tooltip" DefaultValue="Recalculate the current sheet to refresh its Lantern figures"/>
        <bt:String id="TaskpaneButton.Tooltip" DefaultValue="Open the Lantern task pane"/>
      </bt:LongStrings>
    </Resources>
  </VersionOverrides>
</OfficeApp>
