mirror of
				https://github.com/Redocly/redoc.git
				synced 2025-11-04 01:37:32 +03:00 
			
		
		
		
	chore: codeowners
This commit is contained in:
		
							parent
							
								
									8f7e56c747
								
							
						
					
					
						commit
						8240404a55
					
				
							
								
								
									
										2
									
								
								.github/CODEOWNERS
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								.github/CODEOWNERS
									
									
									
									
										vendored
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,2 @@
 | 
			
		|||
* @Redocly/keyboard-warriors
 | 
			
		||||
/docs/ @Redocly/technical-writers
 | 
			
		||||
| 
						 | 
				
			
			@ -33,7 +33,7 @@
 | 
			
		|||
    "start": "webpack serve --mode=development --env playground --hot --config demo/webpack.config.ts",
 | 
			
		||||
    "start:prod": "webpack serve --env playground --mode=production --config demo/webpack.config.ts",
 | 
			
		||||
    "start:benchmark": "webpack serve --mode=production --env.bench --config demo/webpack.config.ts",
 | 
			
		||||
    "test": "npm run lint && npm run unit && npm run license-check",
 | 
			
		||||
    "test": "npm run unit && npm run license-check",
 | 
			
		||||
    "unit": "jest --coverage",
 | 
			
		||||
    "e2e": "cypress run",
 | 
			
		||||
    "e2e-ci": "cypress run --record",
 | 
			
		||||
| 
						 | 
				
			
			@ -49,7 +49,7 @@
 | 
			
		|||
    "stats": "webpack --env production --env standalone --json --profile --mode=production > stats.json",
 | 
			
		||||
    "prettier": "prettier --write \"cli/index.ts\" \"src/**/*.{ts,tsx}\"",
 | 
			
		||||
    "changelog": "conventional-changelog -p angular -i CHANGELOG.md -s -r 1",
 | 
			
		||||
    "lint": "eslint 'src/**/*.{js,ts,tsx}' --cache",
 | 
			
		||||
    "lint": "eslint --fix 'src/**/*.{js,ts,tsx}' --cache",
 | 
			
		||||
    "benchmark": "node ./benchmark/benchmark.js",
 | 
			
		||||
    "start:demo": "webpack serve --hot --config demo/webpack.config.ts --mode=development",
 | 
			
		||||
    "compile:cli": "tsc custom.d.ts cli/index.ts --target es6 --module commonjs --types yargs",
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -26,9 +26,10 @@ export const RedocStandalone = function (props: RedocStandaloneProps) {
 | 
			
		|||
  const normalizedOpts = new RedocNormalizedOptions(options);
 | 
			
		||||
 | 
			
		||||
  if (normalizedOpts.nonce !== undefined) {
 | 
			
		||||
      try {
 | 
			
		||||
        __webpack_nonce__ = normalizedOpts.nonce;
 | 
			
		||||
      } catch { } // If we have exception, Webpack was not used to run this.
 | 
			
		||||
    try {
 | 
			
		||||
      // eslint-disable-next-line  @typescript-eslint/no-unused-vars
 | 
			
		||||
      __webpack_nonce__ = normalizedOpts.nonce;
 | 
			
		||||
    } catch {} // If we have exception, Webpack was not used to run this.
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  return (
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -66,8 +66,11 @@ export const OperationBadge = styled.span.attrs((props: { type: string }) => ({
 | 
			
		|||
  }
 | 
			
		||||
`;
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
function menuItemActive(depth, { theme }: { theme: ResolvedThemeInterface }, option: string): string {
 | 
			
		||||
function menuItemActive(
 | 
			
		||||
  depth,
 | 
			
		||||
  { theme }: { theme: ResolvedThemeInterface },
 | 
			
		||||
  option: string,
 | 
			
		||||
): string {
 | 
			
		||||
  if (depth > 1) {
 | 
			
		||||
    return theme.sidebar.level1Items[option];
 | 
			
		||||
  } else if (depth === 1) {
 | 
			
		||||
| 
						 | 
				
			
			@ -125,7 +128,9 @@ export const MenuItemLabel = styled.label.attrs((props: MenuItemLabelType) => ({
 | 
			
		|||
}))<MenuItemLabelType>`
 | 
			
		||||
  cursor: pointer;
 | 
			
		||||
  color: ${props =>
 | 
			
		||||
    props.active ? menuItemActive(props.depth, props, 'activeTextColor') : props.theme.sidebar.textColor};
 | 
			
		||||
    props.active
 | 
			
		||||
      ? menuItemActive(props.depth, props, 'activeTextColor')
 | 
			
		||||
      : props.theme.sidebar.textColor};
 | 
			
		||||
  margin: 0;
 | 
			
		||||
  padding: 12.5px ${props => props.theme.spacing.unit * 4}px;
 | 
			
		||||
  ${({ depth, type, theme }) =>
 | 
			
		||||
| 
						 | 
				
			
			@ -135,7 +140,9 @@ export const MenuItemLabel = styled.label.attrs((props: MenuItemLabelType) => ({
 | 
			
		|||
  font-family: ${props => props.theme.typography.headings.fontFamily};
 | 
			
		||||
  ${props => menuItemDepth[props.depth]};
 | 
			
		||||
  background-color: ${props =>
 | 
			
		||||
    props.active ? menuItemActive(props.depth, props, 'activeBackgroundColor') : props.theme.sidebar.backgroundColor};
 | 
			
		||||
    props.active
 | 
			
		||||
      ? menuItemActive(props.depth, props, 'activeBackgroundColor')
 | 
			
		||||
      : props.theme.sidebar.backgroundColor};
 | 
			
		||||
 | 
			
		||||
  ${props => (props.deprecated && deprecatedCss) || ''};
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -124,7 +124,7 @@ export class OperationModel implements IMenuItem {
 | 
			
		|||
      // TODO: update getting pathInfo for overriding servers on path level
 | 
			
		||||
      this.servers = normalizeServers('', operationSpec.servers || operationSpec.pathServers || []);
 | 
			
		||||
    } else {
 | 
			
		||||
      this.operationHash = operationSpec.operationId && 'operation/' + operationSpec.operationId
 | 
			
		||||
      this.operationHash = operationSpec.operationId && 'operation/' + operationSpec.operationId;
 | 
			
		||||
      this.id =
 | 
			
		||||
        operationSpec.operationId !== undefined
 | 
			
		||||
          ? (parent ? parent.id + '/' : '') + this.operationHash
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -25,7 +25,7 @@ export class SecurityRequirementModel {
 | 
			
		|||
          return undefined;
 | 
			
		||||
        }
 | 
			
		||||
        const displayName = scheme['x-displayName'] || id;
 | 
			
		||||
               
 | 
			
		||||
 | 
			
		||||
        return {
 | 
			
		||||
          ...scheme,
 | 
			
		||||
          id,
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -141,7 +141,7 @@ const defaultTheme: ThemeInterface = {
 | 
			
		|||
    groupItems: {
 | 
			
		||||
      activeBackgroundColor: theme => darken(0.1, theme.sidebar.backgroundColor),
 | 
			
		||||
      activeTextColor: theme => theme.sidebar.activeTextColor,
 | 
			
		||||
      textTransform: 'uppercase'
 | 
			
		||||
      textTransform: 'uppercase',
 | 
			
		||||
    },
 | 
			
		||||
    level1Items: {
 | 
			
		||||
      activeBackgroundColor: theme => darken(0.05, theme.sidebar.backgroundColor),
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue
	
	Block a user