tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

migration-wizard.stories.mjs (20543B)


      1 /* This Source Code Form is subject to the terms of the Mozilla Public
      2 * License, v. 2.0. If a copy of the MPL was not distributed with this
      3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
      4 
      5 // Imported for side-effects.
      6 import { html } from "lit.all.mjs";
      7 import "chrome://global/content/elements/panel-list.js";
      8 import "browser/components/migration/content/migration-wizard.mjs";
      9 import { MigrationWizardConstants } from "chrome://browser/content/migration/migration-wizard-constants.mjs";
     10 
     11 // Imported for side-effects.
     12 import "toolkit-widgets/named-deck.js";
     13 
     14 window.MozXULElement.insertFTLIfNeeded(
     15  "locales-preview/migrationWizardChromeWindows.ftl"
     16 );
     17 
     18 export default {
     19  title: "Domain-specific UI Widgets/Migration Wizard",
     20  component: "migration-wizard",
     21 };
     22 
     23 const FAKE_MIGRATOR_LIST = [
     24  {
     25    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
     26    key: "chrome",
     27    displayName: "Chrome",
     28    resourceTypes: [
     29      "HISTORY",
     30      "FORMDATA",
     31      "PASSWORDS",
     32      "BOOKMARKS",
     33      "PAYMENT_METHODS",
     34      "EXTENSIONS",
     35    ],
     36    profile: { id: "Default", name: "Default" },
     37    brandImage: "chrome://browser/content/migration/brands/chrome.png",
     38    hasPermissions: true,
     39  },
     40  {
     41    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
     42    key: "chrome",
     43    displayName: "Chrome",
     44    resourceTypes: [
     45      "HISTORY",
     46      "FORMDATA",
     47      "PASSWORDS",
     48      "BOOKMARKS",
     49      "PAYMENT_METHODS",
     50      "EXTENSIONS",
     51    ],
     52    profile: { id: "person-2", name: "Person 2" },
     53    brandImage: "chrome://browser/content/migration/brands/chrome.png",
     54    hasPermissions: true,
     55  },
     56  {
     57    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
     58    key: "ie",
     59    displayName: "Microsoft Internet Explorer",
     60    resourceTypes: ["HISTORY", "BOOKMARKS"],
     61    profile: null,
     62    brandImage: "chrome://global/skin/icons/defaultFavicon.svg",
     63    hasPermissions: true,
     64  },
     65  {
     66    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
     67    key: "edge",
     68    displayName: "Microsoft Edge Legacy",
     69    resourceTypes: ["HISTORY", "FORMDATA", "PASSWORDS", "BOOKMARKS"],
     70    profile: null,
     71    brandImage: "chrome://global/skin/icons/defaultFavicon.svg",
     72    hasPermissions: true,
     73  },
     74  {
     75    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
     76    key: "chromium-edge",
     77    displayName: "Microsoft Edge",
     78    resourceTypes: [
     79      "HISTORY",
     80      "FORMDATA",
     81      "PASSWORDS",
     82      "BOOKMARKS",
     83      "PAYMENT_METHODS",
     84    ],
     85    profile: { id: "Default", name: "Default" },
     86    brandImage: "chrome://browser/content/migration/brands/edge.png",
     87    hasPermissions: true,
     88  },
     89  {
     90    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
     91    key: "brave",
     92    displayName: "Brave",
     93    resourceTypes: [
     94      "HISTORY",
     95      "FORMDATA",
     96      "PASSWORDS",
     97      "BOOKMARKS",
     98      "PAYMENT_METHODS",
     99    ],
    100    profile: { id: "Default", name: "Default" },
    101    brandImage: "chrome://browser/content/migration/brands/brave.png",
    102    hasPermissions: true,
    103  },
    104  {
    105    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
    106    key: "internal-testing",
    107    displayName: "Internal Testing Migrator",
    108    resourceTypes: ["HISTORY", "PASSWORDS", "BOOKMARKS"],
    109    profile: null,
    110    brandImage: "chrome://global/skin/icons/defaultFavicon.svg",
    111    hasPermissions: true,
    112  },
    113  {
    114    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
    115    key: "safari",
    116    displayName: "Safari",
    117    resourceTypes: ["HISTORY", "PASSWORDS", "BOOKMARKS"],
    118    profile: null,
    119    brandImage: "chrome://browser/content/migration/brands/safari.png",
    120    hasPermissions: true,
    121  },
    122  {
    123    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
    124    key: "opera",
    125    displayName: "Opera",
    126    resourceTypes: ["HISTORY", "FORMDATA", "PASSWORDS", "BOOKMARKS"],
    127    profile: { id: "Default", name: "Default" },
    128    brandImage: "chrome://browser/content/migration/brands/opera.png",
    129    hasPermissions: true,
    130  },
    131  {
    132    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
    133    key: "opera-gx",
    134    displayName: "Opera GX",
    135    resourceTypes: ["HISTORY", "FORMDATA", "PASSWORDS", "BOOKMARKS"],
    136    profile: { id: "Default", name: "Default" },
    137    brandImage: "chrome://browser/content/migration/brands/operagx.png",
    138    hasPermissions: true,
    139  },
    140  {
    141    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
    142    key: "vivaldi",
    143    displayName: "Vivaldi",
    144    resourceTypes: ["HISTORY"],
    145    profile: { id: "Default", name: "Default" },
    146    brandImage: "chrome://browser/content/migration/brands/vivaldi.png",
    147    hasPermissions: true,
    148  },
    149  {
    150    type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
    151    key: "no-resources-browser",
    152    displayName: "Browser with no resources",
    153    resourceTypes: [],
    154    profile: { id: "Default", name: "Default" },
    155    brandImage: "chrome://global/skin/icons/defaultFavicon.svg",
    156    hasPermissions: true,
    157  },
    158  {
    159    type: MigrationWizardConstants.MIGRATOR_TYPES.FILE,
    160    key: "file-password-csv",
    161    displayName: "Passwords from CSV file",
    162    brandImage: "chrome://branding/content/document.ico",
    163    resourceTypes: [],
    164    hasPermissions: true,
    165  },
    166  {
    167    type: MigrationWizardConstants.MIGRATOR_TYPES.FILE,
    168    key: "file-bookmarks",
    169    displayName: "Bookmarks from file",
    170    brandImage: "chrome://branding/content/document.ico",
    171    resourceTypes: [],
    172    hasPermissions: true,
    173  },
    174 ];
    175 
    176 const Template = ({
    177  state,
    178  dialogMode,
    179  forceShowImportAll,
    180  hideOptionExpanderSubtitle,
    181  optionExpanderTitleString,
    182  hideSelectAll,
    183  importButtonString,
    184  checkboxMarginInline,
    185  checkboxMarginBlock,
    186  importButtonClass,
    187  selectionHeaderString,
    188  selectionSubheaderString,
    189  dataImportCompleteSuccessString,
    190  headerFontSize,
    191  headerMarginBlock,
    192  headerFontWeight,
    193  subheaderFontSize,
    194  subheaderMarginBlock,
    195  subheaderFontWeight,
    196 }) => html`
    197  <style>
    198    @media (prefers-reduced-motion: no-preference) {
    199      migration-wizard::part(progress-spinner) {
    200        mask: url(./migration/progress-mask.svg);
    201      }
    202    }
    203  </style>
    204 
    205  <div class="card card-no-hover" style="width: fit-content">
    206    <migration-wizard
    207      ?dialog-mode=${dialogMode}
    208      ?force-show-import-all=${forceShowImportAll}
    209      ?hide-option-expander-subtitle=${hideOptionExpanderSubtitle}
    210      option-expander-title-string=${optionExpanderTitleString}
    211      ?hide-select-all=${hideSelectAll}
    212      import-button-string=${importButtonString}
    213      import-button-class=${importButtonClass}
    214      checkbox-margin-inline=${checkboxMarginInline}
    215      checkbox-margin-block=${checkboxMarginBlock}
    216      selection-header-string=${selectionHeaderString}
    217      selection-subheader-string=${selectionSubheaderString}
    218      data-import-complete-success-string=${dataImportCompleteSuccessString}
    219      header-font-size=${headerFontSize}
    220      header-margin-block=${headerMarginBlock}
    221      header-font-weight=${headerFontWeight}
    222      subheader-font-size=${subheaderFontSize}
    223      subheader-margin-block=${subheaderMarginBlock}
    224      subheader-font-weight=${subheaderFontWeight}
    225      .state=${state}
    226    ></migration-wizard>
    227  </div>
    228 `;
    229 
    230 export const LoadingSkeleton = Template.bind({});
    231 LoadingSkeleton.args = {
    232  dialogMode: true,
    233  state: {
    234    page: MigrationWizardConstants.PAGES.LOADING,
    235  },
    236 };
    237 
    238 export const MainSelectorVariant1 = Template.bind({});
    239 MainSelectorVariant1.args = {
    240  dialogMode: true,
    241  state: {
    242    page: MigrationWizardConstants.PAGES.SELECTION,
    243    migrators: FAKE_MIGRATOR_LIST,
    244    showImportAll: false,
    245  },
    246 };
    247 
    248 export const MainSelectorVariant2 = Template.bind({});
    249 MainSelectorVariant2.args = {
    250  dialogMode: true,
    251  state: {
    252    page: MigrationWizardConstants.PAGES.SELECTION,
    253    migrators: FAKE_MIGRATOR_LIST,
    254    showImportAll: true,
    255  },
    256 };
    257 
    258 export const CustomizedSelectionPage = Template.bind({});
    259 CustomizedSelectionPage.args = {
    260  dialogMode: true,
    261  state: {
    262    page: MigrationWizardConstants.PAGES.SELECTION,
    263    migrators: FAKE_MIGRATOR_LIST,
    264    showImportAll: true,
    265  },
    266  forceShowImportAll: false,
    267  hideOptionExpanderSubtitle: false,
    268  hideSelectAll: false,
    269  importButtonString: "Custom Button String",
    270  checkboxMarginInline: "5px",
    271  checkboxMarginBlock: "10px",
    272  importButtonClass: "test-class",
    273  optionExpanderTitleString: "Options",
    274  selectionHeaderString: "Custom Header",
    275  selectionSubheaderString: "Custom Subheader",
    276  dataImportCompleteSuccessString: "Custom Data Import Success",
    277  headerFontSize: "24px",
    278  headerMarginBlock: "0 4px",
    279  headerFontWeight: "590",
    280  subheaderFontSize: "13px",
    281  subheaderMarginBlock: "0 28px",
    282  subheaderFontWeight: "400",
    283 };
    284 
    285 export const NoPermissionMessage = Template.bind({});
    286 NoPermissionMessage.args = {
    287  dialogMode: true,
    288  state: {
    289    page: MigrationWizardConstants.PAGES.SELECTION,
    290    migrators: [
    291      {
    292        type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
    293        key: "chromium",
    294        displayName: "Chromium",
    295        resourceTypes: [],
    296        profile: null,
    297        brandImage: "chrome://browser/content/migration/brands/chromium.png",
    298        hasPermissions: false,
    299        permissionsPath: "/home/user/snap/chromium/common/chromium",
    300      },
    301      {
    302        type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
    303        key: "safari",
    304        displayName: "Safari",
    305        resourceTypes: ["HISTORY", "PASSWORDS", "BOOKMARKS"],
    306        profile: null,
    307        brandImage: "chrome://browser/content/migration/brands/safari.png",
    308        hasPermissions: false,
    309        permissionsPath: "/Users/user/Library/Safari",
    310      },
    311      {
    312        type: MigrationWizardConstants.MIGRATOR_TYPES.BROWSER,
    313        key: "vivaldi",
    314        displayName: "Vivaldi",
    315        resourceTypes: ["HISTORY"],
    316        profile: { id: "Default", name: "Default" },
    317        brandImage: "chrome://browser/content/migration/brands/vivaldi.png",
    318        hasPermissions: true,
    319      },
    320      {
    321        type: MigrationWizardConstants.MIGRATOR_TYPES.FILE,
    322        key: "file-password-csv",
    323        displayName: "Passwords from CSV file",
    324        brandImage: "chrome://branding/content/document.ico",
    325        resourceTypes: [],
    326        hasPermissions: true,
    327      },
    328      {
    329        type: MigrationWizardConstants.MIGRATOR_TYPES.FILE,
    330        key: "file-bookmarks",
    331        displayName: "Bookmarks from file",
    332        brandImage: "chrome://branding/content/document.ico",
    333        resourceTypes: [],
    334        hasPermissions: true,
    335      },
    336    ],
    337    showImportAll: false,
    338  },
    339 };
    340 
    341 export const Progress = Template.bind({});
    342 Progress.args = {
    343  dialogMode: true,
    344  state: {
    345    page: MigrationWizardConstants.PAGES.PROGRESS,
    346    key: "chrome",
    347    progress: {
    348      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.BOOKMARKS]: {
    349        value: MigrationWizardConstants.PROGRESS_VALUE.LOADING,
    350      },
    351      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PASSWORDS]: {
    352        value: MigrationWizardConstants.PROGRESS_VALUE.LOADING,
    353      },
    354      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.HISTORY]: {
    355        value: MigrationWizardConstants.PROGRESS_VALUE.LOADING,
    356      },
    357      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.EXTENSIONS]: {
    358        value: MigrationWizardConstants.PROGRESS_VALUE.LOADING,
    359      },
    360      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.FORMDATA]: {
    361        value: MigrationWizardConstants.PROGRESS_VALUE.LOADING,
    362      },
    363      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PAYMENT_METHODS]: {
    364        value: MigrationWizardConstants.PROGRESS_VALUE.LOADING,
    365      },
    366    },
    367  },
    368 };
    369 
    370 export const PartialProgress = Template.bind({});
    371 PartialProgress.args = {
    372  dialogMode: true,
    373  state: {
    374    page: MigrationWizardConstants.PAGES.PROGRESS,
    375    key: "chrome",
    376    progress: {
    377      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.BOOKMARKS]: {
    378        value: MigrationWizardConstants.PROGRESS_VALUE.LOADING,
    379      },
    380      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PASSWORDS]: {
    381        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    382        message: "14 logins and passwords",
    383      },
    384      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.HISTORY]: {
    385        value: MigrationWizardConstants.PROGRESS_VALUE.LOADING,
    386      },
    387      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.EXTENSIONS]: {
    388        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    389        message: "10 extensions",
    390      },
    391      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.FORMDATA]: {
    392        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    393        message: "Addresses, credit cards, form history",
    394      },
    395      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PAYMENT_METHODS]: {
    396        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    397        message: "6 payment methods",
    398      },
    399    },
    400  },
    401 };
    402 
    403 export const Success = Template.bind({});
    404 Success.args = {
    405  dialogMode: true,
    406  state: {
    407    page: MigrationWizardConstants.PAGES.PROGRESS,
    408    key: "chrome",
    409    progress: {
    410      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.BOOKMARKS]: {
    411        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    412        message: "14 bookmarks",
    413      },
    414      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PASSWORDS]: {
    415        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    416        message: "14 logins and passwords",
    417      },
    418      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.HISTORY]: {
    419        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    420        message: "From the last 180 days",
    421      },
    422      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.EXTENSIONS]: {
    423        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    424        message: "1 extension",
    425      },
    426      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.FORMDATA]: {
    427        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    428        message: "Addresses, credit cards, form history",
    429      },
    430      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PAYMENT_METHODS]: {
    431        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    432        message: "6 payment methods",
    433      },
    434    },
    435  },
    436 };
    437 
    438 export const SuccessWithWarnings = Template.bind({});
    439 SuccessWithWarnings.args = {
    440  dialogMode: true,
    441  state: {
    442    page: MigrationWizardConstants.PAGES.PROGRESS,
    443    key: "chrome",
    444    progress: {
    445      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.BOOKMARKS]: {
    446        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    447        message: "14 bookmarks",
    448      },
    449      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PASSWORDS]: {
    450        value: MigrationWizardConstants.PROGRESS_VALUE.WARNING,
    451        message: "Something didn't work correctly.",
    452      },
    453      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.HISTORY]: {
    454        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    455        message: "From the last 180 days",
    456      },
    457      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.EXTENSIONS]: {
    458        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    459        message: "1 extension",
    460      },
    461      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.FORMDATA]: {
    462        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    463        message: "Addresses, credit cards, form history",
    464      },
    465      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PAYMENT_METHODS]: {
    466        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    467        message: "6 payment methods",
    468      },
    469    },
    470  },
    471 };
    472 
    473 export const ExtensionsPartialSuccess = Template.bind({});
    474 ExtensionsPartialSuccess.args = {
    475  dialogMode: true,
    476  state: {
    477    page: MigrationWizardConstants.PAGES.PROGRESS,
    478    key: "chrome",
    479    progress: {
    480      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.BOOKMARKS]: {
    481        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    482        message: "14 bookmarks",
    483      },
    484      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PASSWORDS]: {
    485        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    486        message: "14 logins and passwords",
    487      },
    488      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.HISTORY]: {
    489        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    490        message: "From the last 180 days",
    491      },
    492      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.EXTENSIONS]: {
    493        value: MigrationWizardConstants.PROGRESS_VALUE.INFO,
    494        message: "5 of 10 extensions",
    495        linkText: "Learn how Firefox matches extensions",
    496        linkURL:
    497          "https://support.mozilla.org/kb/import-data-another-browser#w_import-extensions-from-chrome/",
    498      },
    499      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.FORMDATA]: {
    500        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    501        message: "Addresses, credit cards, form history",
    502      },
    503      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PAYMENT_METHODS]: {
    504        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    505        message: "6 payment methods",
    506      },
    507    },
    508  },
    509 };
    510 
    511 export const ExtensionsImportFailure = Template.bind({});
    512 ExtensionsImportFailure.args = {
    513  dialogMode: true,
    514  state: {
    515    page: MigrationWizardConstants.PAGES.PROGRESS,
    516    key: "chrome",
    517    progress: {
    518      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.BOOKMARKS]: {
    519        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    520        message: "14 bookmarks",
    521      },
    522      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PASSWORDS]: {
    523        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    524        message: "14 logins and passwords",
    525      },
    526      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.HISTORY]: {
    527        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    528        message: "From the last 180 days",
    529      },
    530      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.EXTENSIONS]: {
    531        value: MigrationWizardConstants.PROGRESS_VALUE.WARNING,
    532        message: "No matching extensions",
    533        linkText: "Browse extensions for Firefox",
    534        linkURL: "https://addons.mozilla.org/",
    535      },
    536      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.FORMDATA]: {
    537        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    538        message: "Addresses, credit cards, form history",
    539      },
    540      [MigrationWizardConstants.DISPLAYED_RESOURCE_TYPES.PAYMENT_METHODS]: {
    541        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    542        message: "6 payment methods",
    543      },
    544    },
    545  },
    546 };
    547 
    548 export const FileImportProgress = Template.bind({});
    549 FileImportProgress.args = {
    550  dialogMode: true,
    551  state: {
    552    page: MigrationWizardConstants.PAGES.FILE_IMPORT_PROGRESS,
    553    title: "Importing passwords",
    554    progress: {
    555      [MigrationWizardConstants.DISPLAYED_FILE_RESOURCE_TYPES
    556        .PASSWORDS_FROM_FILE]: {
    557        value: MigrationWizardConstants.PROGRESS_VALUE.LOADING,
    558      },
    559    },
    560  },
    561 };
    562 
    563 export const FileImportSuccess = Template.bind({});
    564 FileImportSuccess.args = {
    565  dialogMode: true,
    566  state: {
    567    page: MigrationWizardConstants.PAGES.FILE_IMPORT_PROGRESS,
    568    title: "Passwords imported successfully",
    569    progress: {
    570      [MigrationWizardConstants.DISPLAYED_FILE_RESOURCE_TYPES.PASSWORDS_NEW]: {
    571        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    572        message: "2 added",
    573      },
    574      [MigrationWizardConstants.DISPLAYED_FILE_RESOURCE_TYPES
    575        .PASSWORDS_UPDATED]: {
    576        value: MigrationWizardConstants.PROGRESS_VALUE.SUCCESS,
    577        message: "14 updated",
    578      },
    579    },
    580  },
    581 };
    582 
    583 export const SafariPermissions = Template.bind({});
    584 SafariPermissions.args = {
    585  dialogMode: true,
    586  state: {
    587    page: MigrationWizardConstants.PAGES.SAFARI_PERMISSION,
    588  },
    589 };
    590 
    591 export const SafariPasswordPermissions = Template.bind({});
    592 SafariPasswordPermissions.args = {
    593  dialogMode: true,
    594  state: {
    595    page: MigrationWizardConstants.PAGES.SAFARI_PASSWORD_PERMISSION,
    596  },
    597 };
    598 
    599 export const ChromeWindowsPasswordPermissions = Template.bind({});
    600 ChromeWindowsPasswordPermissions.args = {
    601  dialogMode: true,
    602  state: {
    603    page: MigrationWizardConstants.PAGES.CHROME_WINDOWS_PASSWORD_PERMISSION,
    604  },
    605 };
    606 
    607 export const NoBrowsersFound = Template.bind({});
    608 NoBrowsersFound.args = {
    609  dialogMode: true,
    610  state: {
    611    page: MigrationWizardConstants.PAGES.NO_BROWSERS_FOUND,
    612    hasFileMigrators: true,
    613  },
    614 };
    615 
    616 export const FileImportError = Template.bind({});
    617 FileImportError.args = {
    618  dialogMode: true,
    619  state: {
    620    page: MigrationWizardConstants.PAGES.SELECTION,
    621    migrators: FAKE_MIGRATOR_LIST,
    622    showImportAll: false,
    623    migratorKey: "file-password-csv",
    624    fileImportErrorMessage: "Some file import error message",
    625  },
    626 };