mirror of
https://github.com/Redocly/redoc.git
synced 2024-11-25 01:53:44 +03:00
chore: remove unused imports after fix in TS@2.9.1
This commit is contained in:
parent
58284b3d99
commit
c7b3e47366
|
@ -1,11 +1,8 @@
|
|||
import * as React from 'react';
|
||||
import Dropdown from 'react-dropdown';
|
||||
|
||||
import styled, {
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
withProps,
|
||||
} from '../styled-components';
|
||||
import { StyledComponentClass } from 'styled-components';
|
||||
import styled, { withProps } from '../styled-components';
|
||||
|
||||
export interface DropdownOption {
|
||||
label: string;
|
||||
|
|
|
@ -1,12 +1,8 @@
|
|||
import { transparentize } from 'polished';
|
||||
import * as React from 'react';
|
||||
|
||||
import styled, {
|
||||
extensionsHook,
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
withProps,
|
||||
} from '../styled-components';
|
||||
import styled, { extensionsHook, withProps } from '../styled-components';
|
||||
|
||||
import { deprecatedCss } from './mixins';
|
||||
|
||||
export const PropertiesTableCaption = styled.caption`
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import { transparentize } from 'polished';
|
||||
import * as React from 'react';
|
||||
|
||||
import styled, { ResolvedThemeInterface, StyledComponentClass } from '../styled-components';
|
||||
import styled from '../styled-components';
|
||||
import { PropertyNameCell } from './fields-layout';
|
||||
|
||||
export const ClickablePropertyNameCell = PropertyNameCell.extend`
|
||||
|
|
|
@ -1,12 +1,6 @@
|
|||
import * as React from 'react';
|
||||
import { InterpolationFunction, Styles, ThemeProps } from 'styled-components';
|
||||
|
||||
import styled, {
|
||||
css,
|
||||
extensionsHook,
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
} from '../styled-components';
|
||||
import styled, { css, extensionsHook } from '../styled-components';
|
||||
|
||||
const headerFontSize = {
|
||||
1: '1.85714em',
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
import * as React from 'react';
|
||||
import { InterpolationFunction, Styles, ThemeProps } from 'styled-components';
|
||||
|
||||
import styled, { css, ResolvedThemeInterface, StyledComponentClass } from '../styled-components';
|
||||
import styled, { css } from '../styled-components';
|
||||
|
||||
// tslint:disable-next-line
|
||||
export const linkifyMixin = className => css`
|
||||
|
|
|
@ -1,6 +1,4 @@
|
|||
import { InterpolationFunction, Styles, ThemeProps } from 'styled-components';
|
||||
|
||||
import { css, StyledComponentClass } from '../styled-components';
|
||||
import { css } from '../styled-components';
|
||||
|
||||
export const deprecatedCss = css`
|
||||
text-decoration: line-through;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import * as React from 'react';
|
||||
import styled, { media, ResolvedThemeInterface, StyledComponentClass } from '../styled-components';
|
||||
import styled, { media } from '../styled-components';
|
||||
|
||||
export const MiddlePanel = styled.div`
|
||||
width: calc(100% - ${props => props.theme.rightPanel.width});
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import * as React from 'react';
|
||||
|
||||
import styled, { ResolvedThemeInterface, StyledComponentClass } from '../styled-components';
|
||||
import styled from '../styled-components';
|
||||
|
||||
export const SampleControls = styled.div`
|
||||
opacity: 0.4;
|
||||
|
|
|
@ -1,9 +1,5 @@
|
|||
import * as React from 'react';
|
||||
import styled, {
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
withProps,
|
||||
} from '../styled-components';
|
||||
import styled, { withProps } from '../styled-components';
|
||||
|
||||
export const OneOfList = styled.ul`
|
||||
margin: 0;
|
||||
|
|
|
@ -1,9 +1,5 @@
|
|||
import * as React from 'react';
|
||||
import styled, {
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
withProps,
|
||||
} from '../styled-components';
|
||||
import styled, { withProps } from '../styled-components';
|
||||
|
||||
const directionMap = {
|
||||
left: '90deg',
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import { Tabs as ReactTabs, TabsProps } from 'react-tabs';
|
||||
import styled, { ResolvedThemeInterface, StyledComponentClass } from '../styled-components';
|
||||
import styled from '../styled-components';
|
||||
|
||||
export { Tab, TabList, TabPanel } from 'react-tabs';
|
||||
|
||||
|
|
|
@ -4,8 +4,6 @@ import * as React from 'react';
|
|||
import { AppStore } from '../../services/AppStore';
|
||||
|
||||
import { MiddlePanel, Row } from '../../common-elements/';
|
||||
import { Markdown } from '../Markdown/Markdown';
|
||||
import { SecurityDefs } from '../SecuritySchemes/SecuritySchemes';
|
||||
|
||||
import { StyledMarkdownBlock } from '../Markdown/styled.elements';
|
||||
import {
|
||||
|
|
|
@ -1,11 +1,7 @@
|
|||
import { AnchorHTMLAttributes, ClassAttributes, HTMLAttributes } from 'react';
|
||||
import * as React from 'react';
|
||||
|
||||
import { H1, MiddlePanel } from '../../common-elements';
|
||||
import styled, {
|
||||
extensionsHook,
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
} from '../../styled-components';
|
||||
import styled, { extensionsHook } from '../../styled-components';
|
||||
|
||||
const delimiterWidth = 15;
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import * as React from 'react';
|
||||
import styled, { ResolvedThemeInterface, StyledComponentClass } from '../../styled-components';
|
||||
import styled from '../../styled-components';
|
||||
|
||||
export const LogoImgEl = styled.img`
|
||||
max-height: ${props => props.theme.logo.maxHeight};
|
||||
|
|
|
@ -1,10 +1,6 @@
|
|||
import { ClassAttributes, HTMLAttributes, HTMLProps } from 'react';
|
||||
import * as React from 'react';
|
||||
|
||||
import styled, {
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
withProps,
|
||||
} from '../../styled-components';
|
||||
import styled, { withProps } from '../../styled-components';
|
||||
|
||||
export const OperationEndpointWrap = styled.div`
|
||||
cursor: pointer;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import * as React from 'react';
|
||||
import styled, { ResolvedThemeInterface, StyledComponentClass } from '../../styled-components';
|
||||
import styled from '../../styled-components';
|
||||
|
||||
import { SampleControls } from '../../common-elements';
|
||||
import { CopyButtonWrapper } from '../../common-elements/CopyButtonWrapper';
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
import { InterpolationFunction, Styles, ThemeProps } from 'styled-components';
|
||||
import { css, ResolvedThemeInterface, StyledComponentClass } from '../../styled-components';
|
||||
import { css } from '../../styled-components';
|
||||
|
||||
export const jsonStyles = css`
|
||||
.redoc-json > .collapser {
|
||||
|
|
|
@ -1,9 +1,5 @@
|
|||
import * as React from 'react';
|
||||
import styled, {
|
||||
keyframes,
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
} from '../../styled-components';
|
||||
import styled, { keyframes } from '../../styled-components';
|
||||
|
||||
const _Spinner = (props: { className?: string; color: string }) => (
|
||||
<svg className={props.className} version="1.1" width="512" height="512" viewBox="0 0 512 512">
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
import * as React from 'react';
|
||||
import styled, { ResolvedThemeInterface, StyledComponentClass } from '../../styled-components';
|
||||
|
||||
import * as DOMPurify from 'dompurify';
|
||||
import { AppStore, MarkdownRenderer, MDXComponentMeta } from '../../services';
|
||||
|
|
|
@ -1,14 +1,7 @@
|
|||
import * as React from 'react';
|
||||
import { InterpolationFunction, Styles, ThemeProps } from 'styled-components';
|
||||
|
||||
import { headerCommonMixin, linkifyMixin } from '../../common-elements';
|
||||
import styled, {
|
||||
css,
|
||||
extensionsHook,
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
withProps,
|
||||
} from '../../styled-components';
|
||||
import styled, { css, extensionsHook, withProps } from '../../styled-components';
|
||||
|
||||
export const linksCss = css`
|
||||
a {
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
import * as React from 'react';
|
||||
import styled from '../../styled-components';
|
||||
import { SecurityRequirements } from '../SecurityRequirement/SecuirityRequirement';
|
||||
|
||||
import { observer } from 'mobx-react';
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
import * as PropTypes from 'prop-types';
|
||||
import * as React from 'react';
|
||||
|
||||
import { RedocNormalizedOptions } from '../services/RedocNormalizedOptions';
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import { ClassAttributes, HTMLAttributes } from 'react';
|
||||
import styled, { ResolvedThemeInterface, StyledComponentClass } from '../../styled-components';
|
||||
import * as React from 'react';
|
||||
import styled from '../../styled-components';
|
||||
|
||||
import { DropdownProps, StyledDropdown } from '../../common-elements';
|
||||
|
||||
|
|
|
@ -1,10 +1,6 @@
|
|||
import { ClassAttributes, HTMLAttributes } from 'react';
|
||||
import * as React from 'react';
|
||||
|
||||
import styled, {
|
||||
media,
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
} from '../../styled-components';
|
||||
import styled, { media } from '../../styled-components';
|
||||
|
||||
export const RedocWrap = styled.div`
|
||||
font-family: ${props => props.theme.baseFont.family};
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import { observer } from 'mobx-react';
|
||||
import * as React from 'react';
|
||||
|
||||
import { MediaContentModel, OperationModel } from '../../services/models';
|
||||
import { OperationModel } from '../../services/models';
|
||||
|
||||
import { RightPanelHeader, Tab, TabList, TabPanel, Tabs } from '../../common-elements';
|
||||
import { PayloadSamples } from '../PayloadSamples/PayloadSamples';
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
import { transparentize } from 'polished';
|
||||
import { ClassAttributes, HTMLAttributes } from 'react';
|
||||
import * as React from 'react';
|
||||
|
||||
import { UnderlinedHeader } from '../../common-elements';
|
||||
import styled, { ResolvedThemeInterface, StyledComponentClass } from '../../styled-components';
|
||||
import { ResponseTitle, ResponseTitleProps } from './ResponseTitle';
|
||||
import styled from '../../styled-components';
|
||||
import { ResponseTitle } from './ResponseTitle';
|
||||
|
||||
export const StyledResponseTitle = styled(ResponseTitle)`
|
||||
padding: 10px;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import * as React from 'react';
|
||||
|
||||
import styled, { ResolvedThemeInterface, StyledComponentClass } from '../../styled-components';
|
||||
import styled from '../../styled-components';
|
||||
import { MenuItemLabel } from '../SideMenu/styled.elements';
|
||||
|
||||
export const SearchWrap = styled.div`
|
||||
|
|
|
@ -1,14 +1,8 @@
|
|||
import * as classnames from 'classnames';
|
||||
import * as React from 'react';
|
||||
import { InterpolationFunction, Styles, ThemeProps } from 'styled-components';
|
||||
|
||||
import { deprecatedCss } from '../../common-elements';
|
||||
import styled, {
|
||||
css,
|
||||
ResolvedThemeInterface,
|
||||
StyledComponentClass,
|
||||
withProps,
|
||||
} from '../../styled-components';
|
||||
import styled, { css, withProps } from '../../styled-components';
|
||||
|
||||
export const OperationBadge = withProps<{ type: string }>(styled.span).attrs({
|
||||
className: props => `operation-type ${props.type}`,
|
||||
|
|
|
@ -3,7 +3,6 @@ import { Component } from 'react';
|
|||
|
||||
import { AppStore } from '../services/';
|
||||
import { RedocRawOptions } from '../services/RedocNormalizedOptions';
|
||||
import { OpenAPISpec } from '../types';
|
||||
import { loadAndBundleSpec } from '../utils';
|
||||
|
||||
export interface StoreProviderProps {
|
||||
|
|
|
@ -9,7 +9,6 @@ function isSameHash(a: string, b: string): boolean {
|
|||
}
|
||||
|
||||
export class IntHistoryService {
|
||||
private causedHashChange: boolean = false;
|
||||
private _emiter;
|
||||
|
||||
constructor() {
|
||||
|
@ -40,7 +39,6 @@ export class IntHistoryService {
|
|||
if (IS_BROWSER) {
|
||||
window.removeEventListener('hashchange', this.emit);
|
||||
}
|
||||
this.causedHashChange = false;
|
||||
}
|
||||
|
||||
@bind
|
||||
|
|
|
@ -2,7 +2,7 @@ import { IS_BROWSER } from '../utils/';
|
|||
import { IMenuItem } from './MenuStore';
|
||||
import { OperationModel } from './models';
|
||||
|
||||
import Worker, { SearchDocument, SearchResult } from './SearchWorker.worker';
|
||||
import Worker from './SearchWorker.worker';
|
||||
|
||||
let worker: new () => Worker;
|
||||
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
import { computed, observable } from 'mobx';
|
||||
import { OpenAPIExternalDocumentation, OpenAPISpec } from '../types';
|
||||
import { OpenAPISpec } from '../types';
|
||||
|
||||
import { MenuBuilder } from './MenuBuilder';
|
||||
import { GroupModel, OperationModel } from './models/';
|
||||
import { ApiInfoModel } from './models/ApiInfo';
|
||||
import { SecuritySchemesModel } from './models/SecuritySchemes';
|
||||
import { OpenAPIParser } from './OpenAPIParser';
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import 'raf/polyfill';
|
||||
import * as Enzyme from 'enzyme';
|
||||
import * as Adapter from 'enzyme-adapter-react-16';
|
||||
import 'raf/polyfill';
|
||||
|
||||
Enzyme.configure({ adapter: new Adapter() });
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import { ComponentClass, StatelessComponent } from 'react';
|
||||
import * as React from 'react';
|
||||
import * as styledComponents from 'styled-components';
|
||||
|
||||
import { ResolvedThemeInterface, ThemeInterface } from './theme';
|
||||
import { ResolvedThemeInterface } from './theme';
|
||||
|
||||
export { ResolvedThemeInterface };
|
||||
|
||||
|
@ -54,7 +54,6 @@ export const media = {
|
|||
};
|
||||
|
||||
export { css, injectGlobal, keyframes, ThemeProvider, withProps };
|
||||
export { StyledComponentClass } from 'styled-components';
|
||||
export default styled;
|
||||
|
||||
export function extensionsHook(styledName: string) {
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
/* tslint:disable:no-implicit-dependencies */
|
||||
|
||||
import { has, set } from 'lodash';
|
||||
import { instanceOf } from 'prop-types';
|
||||
import { RedocNormalizedOptions } from '../services/RedocNormalizedOptions';
|
||||
|
||||
function traverseComponent(root, fn) {
|
||||
if (!root) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user