types APIs
- SimpleOptions
- RootState
- User
- ChainType
- FeedbackCategoryAPI
- FeedbackStatusAPI
- FeedbackUserProfileAPI
- NavItems
- SingleNavItem
- NonNullableChildrenDeep
- SingleArticle
- ColumnType
- DataType
- Hub
- PluginConfig
- RawEventMessage
- DualStakingInfo
- StakingInfo
- SyrupInfo
- CommonStakingInfo
- LairInfo
- StakingBasic
- DualStakingBasic
- SyrupBasic
- Questionnaire
- TaskStatuses
- LoginPayload
- SignupPayload
- MutationType
- ProteinSize
- Config
- Themes
- defaults
- CoordinateSpaceInitial
- Background
- Metric
- Metadata
- TManageValue
- Domain
- Organization
- OrganizationTag
- Scan
- ScanSchema
- Query
- SavedSearch
- Role
- ScanTask
- Vulnerability
- GenericObject
- Annotation
- AnnotationList
- VideoAnnotation
- IconName
- IllustrationName
- INotification
- BottomTabScreens
- KYCScreens
- CCVPScreens
- LoginScreens
- PreAuthScreens
- SignUpScreens
- TFAScreens
- PNVScreens
- ProfileScreens
- SecurityScreens
- SMTYFScreens
- WalletScreens
- WithdrawalScreens
- StackNavigationProps
- Coin
- Country
- TransactionStatus
- SetApiActionPayloadInterface
- LoadingStateInterface
- MessageStateInterface
- UiOptionType
- ApiDiffInterface
- ApiStateInterface
- Account
- NFT
- NFTDetails
- AlertType
- DefaultTemplateOptions
- ProviderProps
- AlertTimer
- AlertInstance
- AlertOptions
- TemplateAlertOptions
- AlertContainerFactory
- ChainBase
- ChainNetwork
- WalletId
- ProposalType
- ChainEventNotification
- WebsocketMessageNames
- WebsocketNamespaces
- NotificationCategories
- InviteCodeAttributes
- IPostNotificationData
- ChainCategoryType
- Screens
- NavigationProperty
- IP
- Maybe
- Tuple
- ChainProperties
- ApiPromise
- ApiAction
- BlueprintOptions
- ContractQuery
- ContractOptions
- ContractTx
- KeyringPair
- ContractDryRunParams
- InstantiateData
- SubmittableExtrinsic
- DbState
- OnInstantiateSuccess$Code
- OnInstantiateSuccess$Hash
- InstantiateState
- ApiState
- OrFalsy
- Bytes
- AbiParam
- Registry
- Weight
- SubmittableResult
- Hash
- CodeBundleDocument
- MyCodeBundles
- ContractDocument
- MyContracts
- Database
- DbStatistics
- UserDocument
- QueuedTxOptions
- TransactionsState
- DropdownOption
- DropdownProps
- ValidFormField
- SetState
- BN
- CallResult
- ContractPromise
- RegistryError
- Abi
- TypeDef
- Validation
- FileState
- UseWeight
- ArgComponentProps
- TypeDefInfo
- UseMetadata
- AbiMessage
- AbiConstructor
- InstantiateProps
- CodeSubmittableResult
- BlueprintSubmittableResult
- BlueprintPromise
- Step2FormData
- TxOptions
- TransactionsQueue
- Keyring
- DbQuery
- UseBalance
- CodeBundle
- ValidateFn
- MetadataState
- UseStepper
- UseToggle
- Party
- Restaurant
- BoardMember
- Id
- Label
- Priority
- Avatar
- PriorityValue
- AuthSetup
- IColumn
- Board
- ITask
- TaskComment
- NewTaskComment
- WithTheme
- UserDetail
- TasksByColumn
- NewTask
- ValueOf
- APIResponse
- Nullable
- Currency
- Route
- Author
- Post
- Category
- Watch
- ComputeCallback
Other Related APIs
types#Screens TypeScript Examples
The following examples show how to use
types#Screens.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: insightDrawer.tsx From iotc-cpm-sample with MIT License | 4 votes |
/**
* This navigator doesn't actually navigate to any screen.
* It is used to have a drawer for chart management by levereging on what react-navigation already offers (gestures, styles...).
* @param props
*/
export default function InsightDrawer(props: DrawerProps) {
const {state, dispatch} = useContext(ConfigContext);
const {currentScreen} = props;
let icon: any = 'bluetooth';
if (state.healthManager) {
if (state.healthManager instanceof AppleHealthManager) {
icon = ({size}: {size: number}) => (
<Image
source={require('../assets/health_kit.png')}
style={{width: 60, height: 60}}
/>
);
} else if (state.healthManager instanceof GoogleFitManager) {
icon = ({size}: {size: number}) => (
<Image
source={require('../assets/google_fit.png')}
style={{width: size, height: size - 5}}
/>
);
}
}
if (
!state.device ||
!state.device.items ||
currentScreen !== Screens.INSIGHT_SCREEN
) {
return null;
}
return (
<SafeAreaView style={style.container}>
<View style={style.header}>
<IconButton
icon={icon}
size={30}
style={{marginLeft: -5, marginRight: 20}}
/>
<View style={{width: '60%', paddingBottom: 100}}>
<View style={{flexDirection: 'row'}}>
<Headline>Sync options</Headline>
<IconButton
onPress={() => {
props.close();
}}
icon="chevron-left"
style={{marginLeft: 40, marginTop: -5}}
/>
</View>
<Detail>Which kind of device data would you like to show?</Detail>
</View>
</View>
<Name style={{marginBottom: 20}}>{state.device.name}</Name>
<Divider />
<ScrollView>
{state.device.items.map((item, index) => (
<View style={style.itemContainer} key={`view-${item.id}`}>
<Item style={{width: 150}}>{item.name}</Item>
{/* pass extra parameter to the ref in order to process and enable only valid ids */}
<Switch
{...{refId: `${item.parentId}/${item.id}`}}
value={item.enabled}
onValueChange={async current => {
await item.enable(current);
// dispatch is needed to update state of device items
dispatch({
type: 'HEALTH_CONNECT',
payload: state.device,
});
}}
/>
</View>
))}
</ScrollView>
</SafeAreaView>
);
}