Template:Birth date and age/doc: Difference between revisions

    No edit summary
    (add year, month, and day aliases to TemplateData)
    Line 84: Line 84:
    ===TemplateData===
    ===TemplateData===
    {{TemplateDataHeader}}
    {{TemplateDataHeader}}
    <TemplateData>
    <templatedata>
    {
    {
            "description": "This template returns a living person's date of birth and current age.",
    "description": "This template returns a living person's date of birth and current age.",
            "params": {
    "params": {
                    "1": {
    "1": {
                            "label": "Year of birth",
    "label": "Year of birth",
                            "description": "The year in which the person was born",
    "description": "The year in which the person was born",
                            "type": "number",
    "type": "number",
                            "required": true
    "required": true,
                    },
    "aliases": [
                    "2": {
    "year"
                            "label": "Month of birth",
    ]
                            "description": "The month (number) in which the person was born",
    },
                            "type": "number",
    "2": {
                            "required": true
    "label": "Month of birth",
                    },
    "description": "The month (number) in which the person was born",
                    "3": {
    "type": "number",
                            "label": "Day of birth",
    "required": true,
                            "description": "The day (number) in which the person was born",
    "aliases": [
                            "type": "number",
    "month"
                            "required": true
    ]
                    },
    },
                    "df": {
    "3": {
                            "label": "Day first",
    "label": "Day of birth",
                            "description": "When set to 'y' or 'yes', the date of birth is output in a DMY format",
    "description": "The day (number) in which the person was born",
                            "type": "string",
    "type": "number",
                            "required": false
    "required": true,
                    },
    "aliases": [
                    "mf": {
    "day"
                            "label": "Month first",
    ]
                            "description": "When set to 'y' or 'yes', stresses that the default MDY date format is intended for the date of birth",
    },
                            "type": "string",
    "df": {
                            "required": false
    "label": "Day first",
                    }
    "description": "When set to 'y' or 'yes', the date of birth is output in a DMY format",
            }
    "type": "string",
    "required": false
    },
    "mf": {
    "label": "Month first",
    "description": "When set to 'y' or 'yes', stresses that the default MDY date format is intended for the date of birth",
    "type": "string",
    "required": false
    }
    }
    }
    }
    </TemplateData>
    </templatedata>