Handling 'state' attribute of Upload Component

The documentation states that in the Upload Component, the state attribute takes a value of type ENUM as shown below in the image.


The enum is declared somewhere in the library but I was unable to import it in my component. When I manually created another enum, the functionality was working.

How do I import the enum declared in the library?

Its currently only exposed from the core package. For simplification we plan to expose all core package types etc also from the wrapper packages.

import { UploadFileState } from '@siemens/ix'; // <--- main package
import { IxUpload } from '@siemens/ix-react';
import React from 'react';

export default () => {
  return <IxUpload state={UploadFileState.UPLOAD_FAILED} />;
};

1 Like