This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export const CatalogPageWrapper = () => { | |
| const featureFlagsApi = useApi(featureFlagsApiRef); | |
| const isNewCatalogEnabled = featureFlagsApi.isActive('new-catalog-search'); | |
| return ( | |
| <Box sx={{ | |
| display: 'flex', | |
| flexDirection: 'column', | |
| height: '100%', | |
| width: '100%', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { useState, useEffect, useCallback } from 'react'; | |
| import { | |
| Alert, | |
| Box, | |
| Switch, | |
| FormControlLabel, | |
| IconButton, | |
| Typography, | |
| } from '@mui/material'; | |
| import { Flag as FlagIcon, Close as CloseIcon } from '@mui/icons-material'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### prefer tanstackquery over react query | |
| We use **TanStack Query (TQ)** for all new Backstage front-end work and phase out legacy React Query code. | |
| **Why TanStack Query?** | |
| * Framework-agnostic core (future-proof if we add non-React widgets) | |
| * Smaller, tree-shakable bundles → faster load times | |
| * Smarter cache & request de-duplication | |
| * First-class Suspense / SSR helpers |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import * as React from 'react'; | |
| import { styled, useTheme, alpha } from '@mui/material/styles'; | |
| import ArrowForwardIosSharpIcon from '@mui/icons-material/ArrowForwardIosSharp'; | |
| import MuiAccordion, { AccordionProps } from '@mui/material/Accordion'; | |
| import MuiAccordionSummary, { | |
| AccordionSummaryProps, | |
| } from '@mui/material/AccordionSummary'; | |
| import MuiAccordionDetails from '@mui/material/AccordionDetails'; | |
| import Typography from '@mui/material/Typography'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* eslint-disable class-methods-use-this */ | |
| type UserProfile = { | |
| name: string; | |
| avatarUrl: string; | |
| balance: number; | |
| }; | |
| abstract class AbstractWallet { | |
| // Returns a promise that resolves an array of strings, each string is an origin | |
| async getOrdinals(): Promise<string[]> { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| pragma solidity ^0.4.19; | |
| import 'zeppelin-solidity/contracts/token/ERC20/MintableToken.sol'; | |
| contract BITTokenTest is MintableToken { | |
| string public name = "BITTokenTest"; | |
| string public symbol = "BIT"; | |
| uint8 public decimals = 18; | |
| } |
NewerOlder