mirror of
				https://github.com/go-gitea/gitea.git
				synced 2025-10-31 10:56:10 +01:00 
			
		
		
		
	Fix a number of typescript issues (#32459)
Fixes 69 typescript errors found in the `admin` and `markup` folders. --------- Co-authored-by: Giteabot <teabot@gitea.io>
This commit is contained in:
		| @@ -153,7 +153,7 @@ export type SvgName = keyof typeof svgs; | ||||
| //  most of the SVG icons in assets couldn't be used directly. | ||||
|  | ||||
| // retrieve an HTML string for given SVG icon name, size and additional classes | ||||
| export function svg(name: SvgName, size = 16, classNames: string|string[]): string { | ||||
| export function svg(name: SvgName, size = 16, classNames?: string|string[]): string { | ||||
|   const className = Array.isArray(classNames) ? classNames.join(' ') : classNames; | ||||
|   if (!(name in svgs)) throw new Error(`Unknown SVG icon: ${name}`); | ||||
|   if (size === 16 && !className) return svgs[name]; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user