> ## Documentation Index
> Fetch the complete documentation index at: https://docs.alumio.com/llms.txt
> Use this file to discover all available pages before exploring further.

# String: Capitalize first word

> Takes the given input string and converts the first letter to a capital. This only works when en phrase starts with a lowercase letter.

export const FormField = ({property, label, required = false, diType, uiPatterns, children}) => {
  const patterns = Array.isArray(uiPatterns) ? uiPatterns : uiPatterns ? [uiPatterns] : [];
  return <div style={{
    margin: '1.5rem 0'
  }}>
      <div style={{
    display: 'flex',
    alignItems: 'baseline',
    flexWrap: 'wrap',
    gap: '0.5rem',
    marginBottom: '0.25rem'
  }}>
        <strong>{label}</strong>
        <span style={{
    fontSize: '0.7rem',
    fontWeight: 600,
    textTransform: 'uppercase',
    letterSpacing: '0.04em',
    color: required ? '#6241f5' : '#6b7280'
  }}>
          {required ? 'Required' : 'Optional'}
        </span>
      </div>

      <div>{children}</div>

      {diType || patterns.length > 0 ? <p style={{
    fontSize: '0.85rem',
    color: '#6b7280',
    marginBottom: 0
  }}>
          {diType ? <>
              See the <a href={`/references/${diType}`}>{diType}</a> reference.{' '}
            </> : null}
          {patterns.length > 0 ? <>
              Accepts a <a href={`/documentation/placeholders-and-patterns/patterns#${patterns[0]}`}>pattern</a>.
            </> : null}
        </p> : null}
    </div>;
};

Capitalises the first letter of a text value and leaves the rest of the value exactly as it is. Use this to tidy up labels, names, or short descriptions that should start with a capital, for example turning "wool scarf" into "Wool scarf". Only the very first character is changed, so the other words in the value keep their original casing.

This documentation describes: [Schema](/schemas/mapper/string-upper-first)

## Fields

This mapper has no settings. It always capitalises the first letter of the value.

## Sample data

| Field  | Value                        |
| ------ | ---------------------------- |
| (none) | capitalises the first letter |

Input:

```json theme={null}
{ "name": "wool scarf" }
```

Output:

```json theme={null}
{ "name": "Wool scarf" }
```

```json Configuration theme={null}
{
  "prototype": "string-upper-first",
  "parameters": {}
}
```
