Skip to content

Latest commit

 

History

History
61 lines (56 loc) · 6.62 KB

ATTRIBUTES.md

File metadata and controls

61 lines (56 loc) · 6.62 KB

Attribute Mapping Explanation

The transpile_attribute_name function is used to map attribute names to their corresponding HTML attribute names. Each key-value pair in the attribute_mapping dictionary represents a mapping from an attribute name to its corresponding HTML attribute name.

Here is an explanation of the purpose of each key-value pair in the attribute_mapping:

  • "idName": "id": Represents the attribute idName which is mapped to the HTML attribute id.
  • "classType": "class": Represents the attribute classType which is mapped to the HTML attribute class.
  • "dataValue": "data-value": Represents the attribute dataValue which is mapped to the HTML attribute data-value.
  • "hrefLink": "href": Represents the attribute hrefLink which is mapped to the HTML attribute href.
  • "srcUrl": "src": Represents the attribute srcUrl which is mapped to the HTML attribute src.
  • "altText": "alt": Represents the attribute altText which is mapped to the HTML attribute alt.
  • "forElement": "for": Represents the attribute forElement which is mapped to the HTML attribute for.
  • "ariaLabel": "aria-label": Represents the attribute ariaLabel which is mapped to the HTML attribute aria-label.
  • "ariaHidden": "aria-hidden": Represents the attribute ariaHidden which is mapped to the HTML attribute aria-hidden.
  • "disabledState": "disabled": Represents the attribute disabledState which is mapped to the HTML attribute disabled.
  • "checkedState": "checked": Represents the attribute checkedState which is mapped to the HTML attribute checked.
  • "requiredField": "required": Represents the attribute requiredField which is mapped to the HTML attribute required.
  • "placeholderText": "placeholder": Represents the attribute placeholderText which is mapped to the HTML attribute placeholder.
  • "maxLengthValue": "maxlength": Represents the attribute maxLengthValue which is mapped to the HTML attribute maxlength.
  • "tabIndexValue": "tabindex": Represents the attribute tabIndexValue which is mapped to the HTML attribute tabindex.
  • "targetFrame": "target": Represents the attribute targetFrame which is mapped to the HTML attribute target.
  • "relAttribute": "rel": Represents the attribute relAttribute which is mapped to the HTML attribute rel.
  • "typeAttribute": "type": Represents the attribute typeAttribute which is mapped to the HTML attribute type.
  • "nameAttribute": "name": Represents the attribute nameAttribute which is mapped to the HTML attribute name.
  • "valueAttribute": "value": Represents the attribute valueAttribute which is mapped to the HTML attribute value.
  • "readOnlyState": "readonly": Represents the attribute readOnlyState which is mapped to the HTML attribute readonly.
  • "autocompleteValue": "autocomplete": Represents the attribute autocompleteValue which is mapped to the HTML attribute autocomplete.
  • "patternAttribute": "pattern": Represents the attribute patternAttribute which is mapped to the HTML attribute pattern.
  • "stepValue": "step": Represents the attribute stepValue which is mapped to the HTML attribute step.
  • "minValue": "min": Represents the attribute minValue which is mapped to the HTML attribute min.
  • "maxValue": "max": Represents the attribute maxValue which is mapped to the HTML attribute max.
  • "multipleFiles": "multiple": Represents the attribute multipleFiles which is mapped to the HTML attribute multiple.
  • "colsNumber": "cols": Represents the attribute colsNumber which is mapped to the HTML attribute cols.
  • "rowsNumber": "rows": Represents the attribute rowsNumber which is mapped to the HTML attribute rows.
  • "wrapAttribute": "wrap": Represents the attribute wrapAttribute which is mapped to the HTML attribute wrap.
  • "downloadFilename": "download": Represents the attribute downloadFilename which is mapped to the HTML attribute download.
  • "mediaAttribute": "media": Represents the attribute mediaAttribute which is mapped to the HTML attribute media.
  • "targetBlank": "target": Represents the attribute targetBlank which is mapped to the HTML attribute target.
  • "targetSelf": "target": Represents the attribute targetSelf which is mapped to the HTML attribute target.
  • "targetParent": "target": Represents the attribute targetParent which is mapped to the HTML attribute target.
  • "targetTop": "target": Represents the attribute targetTop which is mapped to the HTML attribute target.
  • "autoplayAttribute": "autoplay": Represents the attribute autoplayAttribute which is mapped to the HTML attribute autoplay.
  • "controlsAttribute": "controls": Represents the attribute controlsAttribute which is mapped to the HTML attribute controls.
  • "loopAttribute": "loop": Represents the attribute loopAttribute which is mapped to the HTML attribute loop.
  • "mutedAttribute": "muted": Represents the attribute mutedAttribute which is mapped to the HTML attribute muted.
  • "preloadAttribute": "preload": Represents the attribute preloadAttribute which is mapped to the HTML attribute preload.
  • "posterAttribute": "poster": Represents the attribute posterAttribute which is mapped to the HTML attribute poster.
  • "openNewTab": "target": Represents the attribute openNewTab which is mapped to the HTML attribute target.
  • "spellcheckAttribute": "spellcheck": Represents the attribute spellcheckAttribute which is mapped to the HTML attribute spellcheck.
  • "translateAttribute": "translate": Represents the attribute translateAttribute which is mapped to the HTML attribute translate.
  • "contenteditableAttribute": "contenteditable": Represents the attribute contenteditableAttribute which is mapped to the HTML attribute contenteditable.
  • "dirAttribute": "dir": Represents the attribute dirAttribute which is mapped to the HTML attribute dir.
  • "langAttribute": "lang": Represents the attribute langAttribute which is mapped to the HTML attribute lang.
  • "accessKeyAttribute": "accesskey": Represents the attribute accessKeyAttribute which is mapped to the HTML attribute accesskey.
  • "draggableAttribute": "draggable": Represents the attribute draggableAttribute which is mapped to the HTML attribute draggable.
  • "hiddenAttribute": "hidden": Represents the attribute hiddenAttribute which is mapped to the HTML attribute hidden.
  • "roleAttribute": "role": Represents the attribute roleAttribute which is mapped to the HTML attribute role.

These mappings ensure that the appropriate HTML attribute names are used when transpiling the attributes from the source node to the HTML output.