basant307/AI_Governance_Project
048
1import {caseInsensitiveTransform} from './util/case-insensitive-transform.js'2import {create} from './util/create.js'3import {4 booleanish,5 boolean,6 commaSeparated,7 number,8 overloadedBoolean,9 spaceSeparated10} from './util/types.js'11 12export const html = create({13 attributes: {14 acceptcharset: 'accept-charset',15 classname: 'class',16 htmlfor: 'for',17 httpequiv: 'http-equiv'18 },19 mustUseProperty: ['checked', 'multiple', 'muted', 'selected'],20 properties: {21 // Standard Properties.22 abbr: null,23 accept: commaSeparated,24 acceptCharset: spaceSeparated,25 accessKey: spaceSeparated,26 action: null,27 allow: null,28 allowFullScreen: boolean,29 allowPaymentRequest: boolean,30 allowUserMedia: boolean,31 alpha: boolean,32 alt: null,33 as: null,34 async: boolean,35 autoCapitalize: null,36 autoComplete: spaceSeparated,37 autoFocus: boolean,38 autoPlay: boolean,39 blocking: spaceSeparated,40 capture: null,41 charSet: null,42 checked: boolean,43 cite: null,44 className: spaceSeparated,45 closedBy: null,46 colorSpace: null,47 cols: number,48 colSpan: number,49 command: null,50 commandFor: null,51 content: null,52 contentEditable: booleanish,53 controls: boolean,54 controlsList: spaceSeparated,55 coords: number | commaSeparated,56 crossOrigin: null,57 data: null,58 dateTime: null,59 decoding: null,60 default: boolean,61 defer: boolean,62 dir: null,63 dirName: null,64 disabled: boolean,65 download: overloadedBoolean,66 draggable: booleanish,67 encType: null,68 enterKeyHint: null,69 fetchPriority: null,70 form: null,71 formAction: null,72 formEncType: null,73 formMethod: null,74 formNoValidate: boolean,75 formTarget: null,76 headers: spaceSeparated,77 height: number,78 hidden: overloadedBoolean,79 high: number,80 href: null,81 hrefLang: null,82 htmlFor: spaceSeparated,83 httpEquiv: spaceSeparated,84 id: null,85 imageSizes: null,86 imageSrcSet: null,87 inert: boolean,88 inputMode: null,89 integrity: null,90 is: null,91 isMap: boolean,92 itemId: null,93 itemProp: spaceSeparated,94 itemRef: spaceSeparated,95 itemScope: boolean,96 itemType: spaceSeparated,97 kind: null,98 label: null,99 lang: null,100 language: null,101 list: null,102 loading: null,103 loop: boolean,104 low: number,105 manifest: null,106 max: null,107 maxLength: number,108 media: null,109 method: null,110 min: null,111 minLength: number,112 multiple: boolean,113 muted: boolean,114 name: null,115 nonce: null,116 noModule: boolean,117 noValidate: boolean,118 onAbort: null,119 onAfterPrint: null,120 onAuxClick: null,121 onBeforeMatch: null,122 onBeforePrint: null,123 onBeforeToggle: null,124 onBeforeUnload: null,125 onBlur: null,126 onCancel: null,127 onCanPlay: null,128 onCanPlayThrough: null,129 onChange: null,130 onClick: null,131 onClose: null,132 onContextLost: null,133 onContextMenu: null,134 onContextRestored: null,135 onCopy: null,136 onCueChange: null,137 onCut: null,138 onDblClick: null,139 onDrag: null,140 onDragEnd: null,141 onDragEnter: null,142 onDragExit: null,143 onDragLeave: null,144 onDragOver: null,145 onDragStart: null,146 onDrop: null,147 onDurationChange: null,148 onEmptied: null,149 onEnded: null,150 onError: null,151 onFocus: null,152 onFormData: null,153 onHashChange: null,154 onInput: null,155 onInvalid: null,156 onKeyDown: null,157 onKeyPress: null,158 onKeyUp: null,159 onLanguageChange: null,160 onLoad: null,161 onLoadedData: null,162 onLoadedMetadata: null,163 onLoadEnd: null,164 onLoadStart: null,165 onMessage: null,166 onMessageError: null,167 onMouseDown: null,168 onMouseEnter: null,169 onMouseLeave: null,170 onMouseMove: null,171 onMouseOut: null,172 onMouseOver: null,173 onMouseUp: null,174 onOffline: null,175 onOnline: null,176 onPageHide: null,177 onPageShow: null,178 onPaste: null,179 onPause: null,180 onPlay: null,181 onPlaying: null,182 onPopState: null,183 onProgress: null,184 onRateChange: null,185 onRejectionHandled: null,186 onReset: null,187 onResize: null,188 onScroll: null,189 onScrollEnd: null,190 onSecurityPolicyViolation: null,191 onSeeked: null,192 onSeeking: null,193 onSelect: null,194 onSlotChange: null,195 onStalled: null,196 onStorage: null,197 onSubmit: null,198 onSuspend: null,199 onTimeUpdate: null,200 onToggle: null,201 onUnhandledRejection: null,202 onUnload: null,203 onVolumeChange: null,204 onWaiting: null,205 onWheel: null,206 open: boolean,207 optimum: number,208 pattern: null,209 ping: spaceSeparated,210 placeholder: null,211 playsInline: boolean,212 popover: null,213 popoverTarget: null,214 popoverTargetAction: null,215 poster: null,216 preload: null,217 readOnly: boolean,218 referrerPolicy: null,219 rel: spaceSeparated,220 required: boolean,221 reversed: boolean,222 rows: number,223 rowSpan: number,224 sandbox: spaceSeparated,225 scope: null,226 scoped: boolean,227 seamless: boolean,228 selected: boolean,229 shadowRootClonable: boolean,230 shadowRootCustomElementRegistry: boolean,231 shadowRootDelegatesFocus: boolean,232 shadowRootMode: null,233 shadowRootSerializable: boolean,234 shape: null,235 size: number,236 sizes: null,237 slot: null,238 span: number,239 spellCheck: booleanish,240 src: null,241 srcDoc: null,242 srcLang: null,243 srcSet: null,244 start: number,245 step: null,246 style: null,247 tabIndex: number,248 target: null,249 title: null,250 translate: null,251 type: null,252 typeMustMatch: boolean,253 useMap: null,254 value: booleanish,255 width: number,256 wrap: null,257 writingSuggestions: null,258 259 // Legacy.260 // See: https://html.spec.whatwg.org/#other-elements,-attributes-and-apis261 align: null, // Several. Use CSS `text-align` instead,262 aLink: null, // `<body>`. Use CSS `a:active {color}` instead263 archive: spaceSeparated, // `<object>`. List of URIs to archives264 axis: null, // `<td>` and `<th>`. Use `scope` on `<th>`265 background: null, // `<body>`. Use CSS `background-image` instead266 bgColor: null, // `<body>` and table elements. Use CSS `background-color` instead267 border: number, // `<table>`. Use CSS `border-width` instead,268 borderColor: null, // `<table>`. Use CSS `border-color` instead,269 bottomMargin: number, // `<body>`270 cellPadding: null, // `<table>`271 cellSpacing: null, // `<table>`272 char: null, // Several table elements. When `align=char`, sets the character to align on273 charOff: null, // Several table elements. When `char`, offsets the alignment274 classId: null, // `<object>`275 clear: null, // `<br>`. Use CSS `clear` instead276 code: null, // `<object>`277 codeBase: null, // `<object>`278 codeType: null, // `<object>`279 color: null, // `<font>` and `<hr>`. Use CSS instead280 compact: boolean, // Lists. Use CSS to reduce space between items instead281 declare: boolean, // `<object>`282 event: null, // `<script>`283 face: null, // `<font>`. Use CSS instead284 frame: null, // `<table>`285 frameBorder: null, // `<iframe>`. Use CSS `border` instead286 hSpace: number, // `<img>` and `<object>`287 leftMargin: number, // `<body>`288 link: null, // `<body>`. Use CSS `a:link {color: *}` instead289 longDesc: null, // `<frame>`, `<iframe>`, and `<img>`. Use an `<a>`290 lowSrc: null, // `<img>`. Use a `<picture>`291 marginHeight: number, // `<body>`292 marginWidth: number, // `<body>`293 noResize: boolean, // `<frame>`294 noHref: boolean, // `<area>`. Use no href instead of an explicit `nohref`295 noShade: boolean, // `<hr>`. Use background-color and height instead of borders296 noWrap: boolean, // `<td>` and `<th>`297 object: null, // `<applet>`298 profile: null, // `<head>`299 prompt: null, // `<isindex>`300 rev: null, // `<link>`301 rightMargin: number, // `<body>`302 rules: null, // `<table>`303 scheme: null, // `<meta>`304 scrolling: booleanish, // `<frame>`. Use overflow in the child context305 standby: null, // `<object>`306 summary: null, // `<table>`307 text: null, // `<body>`. Use CSS `color` instead308 topMargin: number, // `<body>`309 valueType: null, // `<param>`310 version: null, // `<html>`. Use a doctype.311 vAlign: null, // Several. Use CSS `vertical-align` instead312 vLink: null, // `<body>`. Use CSS `a:visited {color}` instead313 vSpace: number, // `<img>` and `<object>`314 315 // Non-standard Properties.316 allowTransparency: null,317 autoCorrect: null,318 autoSave: null,319 credentialless: boolean,320 disablePictureInPicture: boolean,321 disableRemotePlayback: boolean,322 exportParts: commaSeparated,323 part: spaceSeparated,324 prefix: null,325 property: null,326 results: number,327 security: null,328 unselectable: null329 },330 space: 'html',331 transform: caseInsensitiveTransform332})333 