@maccesar/titools 3.1.0 → 3.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,176 +1,264 @@
1
1
  # Icon Font Libraries
2
2
 
3
+ PurgeTSS ships with four official icon font families, each preconfigured with the TSS classes and `fontFamily` mappings you need to drop icons into Buttons, Labels, and TextFields.
4
+
5
+ For user-defined fonts (Google Fonts, brand typefaces, community icon libraries like map-icons or microns), see [Custom Fonts](./custom-fonts.md) — those use `build-fonts`, not `icon-library`.
6
+
3
7
  > ℹ️ **INFO — Official Icon Fonts for PurgeTSS**
4
- >
5
- > Older versions of PurgeTSS bundled additional icon font libraries — Bootstrap Icons, Boxicons, LineIcons, and Tabler Icons among them. **Those libraries have been deprecated and removed from the official distribution** to keep maintenance under control. They are still usable, but you must rebuild them yourself with `build-fonts` (see below).
6
- >
7
- > The icon fonts officially supported and shipped by PurgeTSS today are:
8
- >
9
8
  > - [Font Awesome 7 Free](https://fontawesome.com) (upgrade with `purgetss il -v=fa`)
10
- > - [Framework 7](https://framework7.io/icons/)
9
+ > - [Framework 7 Icons](https://framework7.io/icons/)
11
10
  > - [Material Icons](https://fonts.google.com/icons?icon.set=Material+Icons)
12
11
  > - [Material Symbols](https://fonts.google.com/icons?icon.set=Material+Symbols)
12
+ >
13
+ > Older versions of PurgeTSS bundled additional libraries (Bootstrap Icons, Boxicons, LineIcons, Tabler Icons). They were removed to keep maintenance under control, but you can [recreate them at the bottom of this page](#recreating-removed-icon-libraries).
13
14
 
14
- For the official install flow for the supported vendors, see [CLI Commands](./cli-commands.md#icon-library-command).
15
+ ## Icon families reference
15
16
 
16
- ## Recreate Removed Libraries
17
+ Each family ships one or more variant classes, each pointing to a specific font file. Combine a variant class with an icon class to render a glyph. For example, `msr ms-home` uses the Material Symbols Rounded font with the `home` icon.
17
18
 
18
- You can recreate any deprecated library using the `build-fonts` command.
19
+ | Family | Variant | Class | `fontFamily` |
20
+ |---|---|---|---|
21
+ | **Material Symbols** | Outlined (default) | `.ms` | `MaterialSymbolsOutlined-Regular` |
22
+ | Material Symbols | Outlined (alias) | `.mso` | `MaterialSymbolsOutlined-Regular` |
23
+ | Material Symbols | Rounded | `.msr` | `MaterialSymbolsRounded-Regular` |
24
+ | Material Symbols | Sharp | `.mss` | `MaterialSymbolsSharp-Regular` |
25
+ | **Font Awesome** | Solid (default) | `.fa` | `FontAwesome7Free-Solid` |
26
+ | Font Awesome | Solid (alias) | `.fas` | `FontAwesome7Free-Solid` |
27
+ | Font Awesome | Regular | `.far` | `FontAwesome7Free-Regular` |
28
+ | Font Awesome | Brands | `.fab` | `FontAwesome7Brands-Regular` |
29
+ | **Material Icons** | Regular | `.mi` | `MaterialIcons-Regular` |
30
+ | **Framework 7** | Regular | `.f7` | `Framework7-Icons` |
19
31
 
20
- ### 1. Download the Libraries
32
+ > 💡 **TIP Icon class names**
33
+ > Across a family, the icon class is shared by every variant. For Material Symbols, there is one `ms-home` class; pair it with `.ms`, `.mso`, `.msr`, or `.mss` to pick the shape (outlined, rounded, or sharp). FontAwesome works the same way: `fa-home` pairs with `.fa`/`.fas` (Solid) or `.far` (Regular), while brand icons like `fa-github` need `.fab`. **The variant class chooses the font file. The icon class chooses the glyph.**
21
34
 
22
- Start by downloading the libraries from their official websites:
35
+ ### Full class lists
23
36
 
24
- - [Bootstrap Icons](https://icons.getbootstrap.com)
25
- - [Boxicons](https://boxicons.com)
26
- - [LineIcons](https://lineicons.com/icons/?type=free)
27
- - [Tabler Icons](https://tabler-icons.io)
37
+ The complete class definitions live in the PurgeTSS `dist/` folder:
28
38
 
29
- ### 2. The `fonts` Folder
39
+ - [fontawesome.tss](https://github.com/macCesar/purgeTSS/blob/main/dist/fontawesome.tss)
40
+ - [materialicons.tss](https://github.com/macCesar/purgeTSS/blob/main/dist/materialicons.tss)
41
+ - [materialsymbols.tss](https://github.com/macCesar/purgeTSS/blob/main/dist/materialsymbols.tss)
42
+ - [framework7icons.tss](https://github.com/macCesar/purgeTSS/blob/main/dist/framework7icons.tss)
30
43
 
31
- Put the desired libraries in the `./purgetss/fonts` folder.
44
+ ## Installing the icon fonts
32
45
 
33
- > ℹ️ **INFO**
34
- > Copy the TrueType or OpenType font files and the `.css` file.
46
+ Run `icon-library` to copy the `.ttf` files into `./app/assets/fonts/`. That is the only step you need. Once the fonts are in place, the icon classes from the table above work out of the box.
35
47
 
36
48
  ```bash
37
- purgetss
38
- └─ fonts
39
- └─ boxicons
40
- ├─ boxicons.css
41
- └─ boxicons.ttf
42
- └─ lineicons
43
- ├─ lineicons.css
44
- └─ lineicons.ttf
49
+ # All four families
50
+ $ purgetss icon-library
51
+
52
+ # Selective install
53
+ $ purgetss il -v=fa,mi,ms,f7
45
54
  ```
46
55
 
47
- ### 3. The `build-fonts` Command
56
+ > ℹ️ **INFO — You do not need the `.tss` files in `./purgetss/styles/`**
57
+ > PurgeTSS already knows every official icon class and resolves them at compile time from its own bundled `dist/` files. You do not need `fontawesome.tss`, `materialsymbols.tss`, `materialicons.tss`, or `framework7icons.tss` inside `./purgetss/styles/` for `class="fas fa-home"` (or any other icon class) to work in your XML and controllers. Install the `.ttf` files with `icon-library` and the classes are ready.
58
+
59
+ ### Optional flags
48
60
 
49
- Run the `build-fonts` command to create a custom `fonts.tss` file.
61
+ Two optional flags adjust what `icon-library` copies into your project:
62
+
63
+ - `-s, --styles`: copies the official `.tss` source files into `./purgetss/styles/` for reference only. Useful if you want to grep the full class list, see how a class is defined, or override a specific class in your own project.
64
+ - `-m, --module`: copies the matching CommonJS module into `./app/lib/`, which exposes each icon's Unicode string to JavaScript. Handy when you set `label.text` from a controller and prefer a friendly name like `icons.fa.home` over a raw ``.
50
65
 
51
66
  ```bash
52
- purgetss build-fonts [--modules]
67
+ # Add either flag when you want them
68
+ $ purgetss il -s
69
+ $ purgetss il -m
70
+ $ purgetss il -m -s
71
+ ```
72
+
73
+ ### Vendor aliases
74
+
75
+ `--vendor` accepts the short or long forms:
76
+
77
+ - `fa`, `fontawesome` = Font Awesome Icons
78
+ - `mi`, `materialicons` = Material Icons
79
+ - `ms`, `materialsymbol` = Material Symbols
80
+ - `f7`, `framework7` = Framework7 Icons
81
+
82
+ ## Using icons in XML
83
+
84
+ The variant class sets the `fontFamily`. The icon class sets the glyph (`text` / `title`). Apply both together:
85
+
86
+ `index.xml`
87
+ ```xml
88
+ <Alloy>
89
+ <Window>
90
+ <View class="grid">
91
+ <View class="vertical mx-auto grid-cols-2 gap-y-2">
92
+ <!-- Material Symbols variants -->
93
+ <Label class="mt-2 text-gray-700" text="Material Symbols" />
94
+ <Button class="ms ms-home my-1 h-10 w-10 text-xl text-blue-500" />
95
+ <Button class="msr ms-home my-1 h-10 w-10 text-xl text-blue-500" />
96
+ <Button class="mss ms-home my-1 h-10 w-10 text-xl text-blue-500" />
97
+ </View>
98
+
99
+ <View class="vertical mx-auto grid-cols-2 gap-y-2">
100
+ <!-- FontAwesome variants -->
101
+ <Label class="mt-2 text-gray-700" text="Font Awesome" />
102
+ <Button class="fas fa-home my-1 h-10 w-10 text-xl text-blue-500" />
103
+ <Button class="far fa-bell my-1 h-10 w-10 text-xl text-blue-500" />
104
+ <Button class="fab fa-github my-1 h-10 w-10 text-xl text-blue-500" />
105
+ </View>
106
+ </View>
107
+ </Window>
108
+ </Alloy>
109
+ ```
53
110
 
54
- # alias:
55
- purgetss bf [-m]
111
+ ## Complete example with all four families
112
+
113
+ A side-by-side example using all four official families.
114
+
115
+ To use this file:
116
+
117
+ - Copy the content of `index.xml` into a new Alloy project.
118
+ - Install the official icon font files using `purgetss icon-library` (without `--vendor`, PurgeTSS copies all official icon fonts).
119
+ - Run `purgetss` once to generate the required files.
120
+ - Compile your app as usual.
121
+ - Use `liveview` if you want faster testing.
122
+
123
+ `index.xml`
124
+ ```xml
125
+ <Alloy>
126
+ <Window>
127
+ <View class="grid">
128
+ <View class="vertical mx-auto grid-cols-2 gap-y-2">
129
+ <!-- FontAwesome -->
130
+ <Label class="mt-2 text-gray-700" text="FontAwesome" />
131
+ <Button class="fa fa-home my-1 h-10 w-10 text-xl text-blue-500" />
132
+ <Button class="fa fa-home my-1 h-10 w-10 rounded bg-blue-500 text-xl text-white" />
133
+ </View>
134
+
135
+ <View class="vertical mx-auto grid-cols-2 gap-y-2">
136
+ <!-- Material Icons -->
137
+ <Label class="mt-2 text-gray-700" text="Material Icons" />
138
+ <Button class="mi mi-home my-1 h-10 w-10 text-xl text-blue-500" />
139
+ <Button class="mi mi-home my-1 h-10 w-10 rounded bg-blue-500 text-xl text-white" />
140
+ </View>
141
+
142
+ <View class="vertical mx-auto grid-cols-2 gap-y-2">
143
+ <!-- Material Symbols -->
144
+ <Label class="mt-2 text-gray-700" text="Material Symbol" />
145
+ <Button class="ms ms-home my-1 h-10 w-10 text-xl text-blue-500" />
146
+ <Button class="ms ms-home my-1 h-10 w-10 rounded bg-blue-500 text-xl text-white" />
147
+ </View>
148
+
149
+ <View class="vertical mx-auto grid-cols-2 gap-y-2">
150
+ <!-- Framework7-Icons -->
151
+ <Label class="mt-2 text-gray-700" text="Framework7-Icons" />
152
+ <Button class="f7 f7-house my-1 h-10 w-10 text-xl text-blue-500" />
153
+ <Button class="f7 f7-house my-1 h-10 w-10 rounded bg-blue-500 text-xl text-white" />
154
+ </View>
155
+ </View>
156
+ </Window>
157
+ </Alloy>
56
158
  ```
57
159
 
58
- ### The `fonts.tss` File
160
+ Generated `app.tss` excerpt:
161
+ ```css
162
+ // PurgeTSS v7.10.2
163
+ // Created by César Estrada
164
+ // https://purgetss.com
59
165
 
60
- The `build-fonts` command generates `./purgetss/styles/fonts.tss` with Unicode characters and style rules.
166
+ /* Ti Elements */
167
+ 'View': { width: Ti.UI.SIZE, height: Ti.UI.SIZE }
168
+ 'Window': { backgroundColor: '#FFFFFF' }
61
169
 
62
- `./purgetss/styles/fonts.tss`
63
- ```tss
64
- '.boxicons': { font: { fontFamily: 'boxicons' } }
65
- '.lineicons': { font: { fontFamily: 'LineIcons' } }
170
+ /* Default Font Awesome */
171
+ '.fa': { font: { fontFamily: 'FontAwesome7Free-Solid' } }
172
+ '.fa-home': { text: '', title: '' }
66
173
 
67
- /* Unicode Characters */
68
- /* To use your Icon Fonts in Buttons AND Labels each class sets 'text' and 'title' properties */
174
+ /* Material Icons */
175
+ '.mi': { font: { fontFamily: 'MaterialIcons-Regular' } }
176
+ '.mi-home': { text: '', title: '' }
69
177
 
70
- /* boxicons.css */
71
- '.bxl-meta': { text: '', title: '' }
72
- '.bx-lemon': { text: '', title: '' }
73
- /* ... */
178
+ /* Material Symbols */
179
+ '.ms': { font: { fontFamily: 'MaterialSymbolsOutlined-Regular' } }
180
+ '.ms-home': { text: '', title: '' }
74
181
 
75
- /* lineicons.css */
76
- '.lni-500px': { text: '', title: '' }
77
- '.lni-add-files': { text: '', title: '' }
78
- /* ... */
182
+ /* Framework7 */
183
+ '.f7': { font: { fontFamily: 'Framework7-Icons' } }
184
+ '.f7-house': { text: 'house', title: 'house' }
79
185
  ```
80
186
 
81
- ### Rename the Style Rule Name
187
+ ## Customizing Font Awesome
82
188
 
83
- PurgeTSS uses the font file name as the style rule name. You can change it by renaming the font file.
189
+ If you have a [Font Awesome Pro account](https://fontawesome.com/pro) or want to try the Beta, PurgeTSS can generate a custom `./purgetss/styles/fontawesome.tss` with the Pro or Beta classes.
84
190
 
85
- `./purgetss/fonts/`
86
- ```bash
87
- purgetss
88
- └─ fonts
89
- └─ boxicons
90
- └─ bx.ttf
91
- ```
191
+ ### Font Awesome Pro
92
192
 
93
- New style rule name: `'.bx'`
193
+ After setting the [@fortawesome scope](https://fontawesome.com/how-to-use/on-the-web/setup/using-package-managers#installing-pro) with your token, install it in your project's root folder with `npm init` and `npm install --save-dev @fortawesome/fontawesome-pro` (current version 7.1.0).
94
194
 
95
- ```tss
96
- '.bx': { font: { fontFamily: 'boxicons' } }
97
- ```
195
+ To generate a new `purgetss/styles/fontawesome.tss`, run `purgetss build`. It also copies the Pro font files into `./app/assets/fonts` if needed.
98
196
 
99
- ### The `assets/fonts` Folder
197
+ Note: Titanium cannot use Font Awesome duotone icons because each icon uses two glyphs.
100
198
 
101
- The `build-fonts` command copies the font files to `./app/assets/fonts` and renames them to their PostScript names so they work on both iOS and Android.
199
+ ### Font Awesome 7 Beta
102
200
 
103
- ```bash
104
- app
105
- └─ assets
106
- └─ fonts
107
- ├─ boxicons.ttf
108
- └─ LineIcons.ttf
109
- ```
201
+ To generate a custom `fontawesome.tss` file from [Font Awesome 7 Beta](https://fontawesome.com/download):
110
202
 
111
- ### The `--modules` Option
112
-
113
- When you use the `--modules` option, it generates a `./app/lib/purgetss.fonts.js` CommonJS module file.
114
-
115
- `./app/lib/purgetss.fonts.js`
116
- ```javascript
117
- const icons = {
118
- /* boxicons */
119
- boxicons: {
120
- bxlMeta: '',
121
- bxLemon: ''
122
- /* ... */
123
- },
124
- /* lineicons */
125
- lni: {
126
- '500px': '',
127
- addFiles: ''
128
- /* ... */
129
- }
130
- };
131
- exports.icons = icons;
132
- ```
203
+ Move the `css` and `webfonts` folders from `fontawesome-pro-7.0.0-beta3-web/`:
133
204
 
134
- ### The `--prefix` Option
205
+ ```bash
206
+ fontawesome-pro-7.0.0-beta3-web
207
+ └─ css
208
+ └─ webfonts
209
+ ```
135
210
 
136
- PurgeTSS determines the group's prefix for each icon family and class name. Use `--prefix` to apply the style's filename as the prefix for class names in `fonts.tss` and property names in `purgetss.fonts.js`.
211
+ Into `./purgetss/fontawesome-beta`:
137
212
 
138
- `./purgetss/fonts/`
139
213
  ```bash
140
214
  purgetss
141
- └─ fonts
142
- └─ lineicons
143
- └─ li.css
215
+ └─ fontawesome-beta
216
+ ├─ css
217
+ └─ webfonts
144
218
  ```
145
219
 
146
- New group prefix: `li`
220
+ Then run `purgetss build` to generate your custom `fontawesome.tss` file and test the new icons.
221
+
222
+ ## Recreating removed icon libraries
223
+
224
+ Older versions of PurgeTSS bundled Bootstrap Icons, Boxicons, LineIcons, and Tabler Icons. The list was trimmed to make maintenance easier, but you can rebuild any of them:
225
+
226
+ 1. Download the library from its official site:
227
+ - [Bootstrap Icons](https://icons.getbootstrap.com)
228
+ - [Boxicons](https://boxicons.com)
229
+ - [LineIcons](https://lineicons.com/icons/?type=free)
230
+ - [Tabler Icons](https://tabler-icons.io)
231
+ 2. Place the `.ttf`/`.otf` and `.css` files into `./purgetss/fonts/<library>/`.
232
+ 3. Run `purgetss build-fonts`.
233
+
234
+ For the underlying mechanics (how `build-fonts` reads the `.css`, options like `-m` and `-f`), see [Custom Fonts](./custom-fonts.md).
235
+
236
+ ### `fonts.tss` example
237
+
238
+ ```css
239
+ '.boxicons': { font: { fontFamily: 'boxicons' } }
240
+ '.lineicons': { font: { fontFamily: 'LineIcons' } }
241
+
242
+ /* Unicode Characters */
243
+ /* To use your Icon Fonts in Buttons AND Labels each class sets 'text' and 'title' properties */
147
244
 
148
- `./purgetss/styles/fonts.tss`
149
- ```tss
150
- /* lineicons/li.css */
151
- '.li-zoom-out': { text: '', title: '' }
152
- '.li-zoom-in': { text: '', title: '' }
245
+ /* boxicons.css */
246
+ '.bxl-meta': { text: '', title: '' }
247
+ '.bx-lemon': { text: '', title: '' }
153
248
  /* ... */
154
- ```
155
249
 
156
- `./app/lib/purgetss.fonts.js`
157
- ```javascript
158
- const icons = {
159
- /* lineicons/li.css */
160
- li: {
161
- /* ... */
162
- }
163
- };
164
- exports.icons = icons;
250
+ /* lineicons.css */
251
+ '.lni-500px': { text: '', title: '' }
252
+ '.lni-add-files': { text: '', title: '' }
253
+ /* ... */
165
254
  ```
166
255
 
167
- > 🛑 **DANGER**
168
- >
169
- > Make sure the new prefix stays unique so it does not collide with other class prefixes. A duplicate prefix will silently overwrite earlier rules in the generated `fonts.tss`, leaving you with icons that render the wrong glyph at runtime.
170
-
171
256
  ## Community-Discovered Patterns
172
257
 
173
258
  The following note reflects community experience working with icon fonts that depend on multiple glyphs per icon.
174
259
 
175
260
  > 🛑 **DANGER — Font Awesome Duotone**
176
261
  > Titanium cannot render Font Awesome duotone icons correctly because each icon uses two glyphs. If you work with Font Awesome Pro, avoid documenting duotone as supported.
262
+
263
+ > 💡 **Mixing variant + icon in `class=`**
264
+ > A common mistake is omitting the variant class and writing just `class="fa-github"`. The icon class only sets `text`/`title` (the glyph) — without the variant class (`.fa`, `.fas`, `.fab`, etc.) the `fontFamily` is missing and the glyph renders as the system font's fallback character. Always include both: `class="fab fa-github"` or `class="msr ms-home"`.
@@ -88,7 +88,7 @@ purgetss
88
88
 
89
89
  - `fonts`
90
90
 
91
- Place icon, serif, sans-serif, or monospace font files here. See the [`build-fonts` command](./cli-commands.md#purgetss-build-fonts-alias-bf) for instructions.
91
+ Place icon, serif, sans-serif, or monospace font files here. See [Custom Fonts](./custom-fonts.md) for the full guide, or [`build-fonts` Command](./cli-commands.md#build-fonts-command) for the terse flag reference.
92
92
 
93
93
  > **CAUTION**
94
94
  > **PurgeTSS overwrites your existing `app.tss` file.**
@@ -152,9 +152,9 @@ To use the example files:
152
152
  > Every time `purgetss` runs, it copies the content of `_app.tss` to `app.tss`.
153
153
 
154
154
  ```tss
155
- /* PurgeTSS v7.2.7 */
156
- /* Created by César Estrada */
157
- /* https://github.com/macCesar/purgeTSS */
155
+ // PurgeTSS v7.10.2
156
+ // Created by César Estrada
157
+ // https://purgetss.com
158
158
 
159
159
  /* _app.tss styles */
160
160
  '.bg-primary': {
@@ -1,11 +1,168 @@
1
1
  # Migration Guide
2
2
 
3
- This guide mirrors the official PurgeTSS changelog (see the project `README.md` / `docs/index.md`). It walks through the upgrade-relevant changes from v7.2.6 through v7.6.0, flags breaking changes, and links each section to the reference files that cover the new surface area in depth.
3
+ This guide mirrors the official PurgeTSS changelog (see the project `README.md` / `docs/index.md`). It walks through the upgrade-relevant changes from v7.2.6 through v7.10.x, flags breaking changes, and links each section to the reference files that cover the new surface area in depth.
4
4
 
5
5
  Changelog source of truth: [https://github.com/macCesar/purgeTSS](https://github.com/macCesar/purgeTSS).
6
6
 
7
7
  ---
8
8
 
9
+ ## Upgrade to v7.10.x
10
+
11
+ v7.10.0 through v7.10.2 are additive — **no breaking changes**. The notable shift is internal: configs written before v7.7.0 (the `brand:` regroup) now auto-migrate in memory on every run, so projects that never updated to the grouped `brand:` schema keep working without a `TypeError` crash. Full release notes in [`version-history.md`](./version-history.md).
12
+
13
+ ### Added in v7.10.0
14
+
15
+ - **`purgetss images --opacity / --padding / --output`** — three CLI-only flags aimed at placeholder / default ImageView workflows. `--opacity` multiplies alpha; `--padding` shrinks the rendered image inside each density canvas; `--output` retargets the basename and subpath. See [`multi-density-images.md`](./multi-density-images.md).
16
+ - **Google Play Feature Graphic in `brand`** — `purgetss brand` now generates `MarketplaceArtworkFeature.png` (1024×500). Auto-discovers `purgetss/brand/logo-feature.{svg,png}` or reuses the master logo. Tune with `--feature-graphic-padding <n>` (range `0-40`, default `12%`), `brand.padding.featureGraphic`, or `--feature-logo <path>`. See [`app-branding.md`](./app-branding.md).
17
+ - **Arbitrary nesting depth in `theme` objects** — property emission walks nested values recursively instead of stopping at level 2. `theme.extend.colors.brand.primary.500` now flattens to `brand-primary-500` instead of being silently dropped. Default keys (`default`, `global`, `DEFAULT`) collapse without contributing to the suffix. See [`arbitrary-values.md`](./arbitrary-values.md).
18
+ - **`apply:` resolves bundled icon fonts from `dist/`** — `apply: 'fas fa-times-circle wh-12 ...'` now merges the FontAwesome family and glyph automatically. Same lookup runs for `mi-*` (Material Icons), `ms-*` (Material Symbols), and `f7-*` (Framework7). Project-level `purgetss/styles/fontawesome.tss` still wins over the bundled default. See [`apply-directive.md`](./apply-directive.md).
19
+
20
+ ### Fixed in v7.10.0
21
+
22
+ - **`borderRadius` arrays inside `apply:`** — the post-merge dedup step now tracks depth on `[]` alongside `{}`, so directional rules like `rounded-{t,b,l,r,tl,tr,bl,br}-*` no longer get split on internal commas.
23
+ - **`brand --padding <n>` shortcut** — now applies to BOTH Android paddings (`androidAdaptivePadding` AND `androidLegacyPadding`) as the help text always promised. Previously only fed the adaptive one.
24
+
25
+ ### v7.10.1 — copy-only changes
26
+
27
+ - **"Tailwind" framing dropped** from copy that did not document a functional integration. Error block now reports `Square brackets "[ ]" are not supported` (previously `Tailwind-style brackets "[ ]"`). The promotional `<Label>` injected into new projects by `purgetss create` changed from `"Tailwind-inspired utility classes for Titanium/Alloy"` to `"Utility-first styling for Titanium/Alloy"`.
28
+ - **Functional integrations stay**: `tailwindcss@3` dependency installed by `install-dependencies` (drives the `defaultColors` / `defaultTheme` palette base AND the VSCode IntelliSense extension); `--tailwind` flag on `purgetss shades`; recommended `Tailwind CSS IntelliSense` and `Tailwind Raw Reorder (v4)` VSCode extensions.
29
+
30
+ ### v7.10.2 — pre-7.7.0 brand config auto-migration
31
+
32
+ If your project still uses the **flat** `brand:` config that predates v7.7.0, v7.10.2 normalizes it in memory on every run before defaults are applied. Without this, the build crashed with `TypeError: Cannot create property 'ios' on number '15'` because `brand.padding` was a number, not an object.
33
+
34
+ Mapping (see [`app-branding.md` → Upgrading from pre-7.7.0 configs](./app-branding.md#upgrading-from-pre-7-7-0-configs)):
35
+
36
+ | Pre-7.7.0 flat key | Current grouped key |
37
+ | --- | --- |
38
+ | `brand.padding: <number\|string>` | `brand.padding.androidLegacy` AND `brand.padding.androidAdaptive` (same value applied to both) |
39
+ | `brand.iosPadding` | `brand.padding.ios` |
40
+ | `brand.bgColor` | `brand.colors.background` |
41
+ | `brand.darkBgColor` | `brand.ios.darkBackground` |
42
+ | `brand.notification` | `brand.android.notification` |
43
+ | `brand.splash` | `brand.android.splash` |
44
+
45
+ The grouped key always wins when both forms coexist. A one-time deprecation notice per session lists which legacy keys were migrated. Auto-migration is transitional and may be removed in a future major version — update `config.cjs` to the grouped schema to silence the notice and stay future-proof.
46
+
47
+ ### What to review
48
+
49
+ - If you maintain a `brand:` block from pre-7.7.0, plan the one-time update to the grouped schema (`logos`, `padding`, `android`, `ios`, `colors`).
50
+ - If you previously skipped `apply:` with icon fonts because they were silently dropped, that workaround is no longer needed in v7.10.0.
51
+ - Deeply nested color families in `theme.extend.colors.*` that you flattened by hand to stay at depth ≤ 2 can be restructured by domain — the recursive emission now reaches every leaf.
52
+
53
+ ---
54
+
55
+ ## Upgrade to v7.9.0
56
+
57
+ v7.9.0 ships one **breaking** path rename plus a behavior change for `theme.Window` / `theme.View` / `theme.ImageView` that can surface as a regression if a project depended on the framework defaults being merged in.
58
+
59
+ ### Breaking — glossary output path renamed
60
+
61
+ The user-facing glossary output path moved from `purgetss/experimental/tailwind-classes/` to `purgetss/glossary/tailwind-classes/`. Tooling or CI that reads from the old path needs updating on upgrade — no transition shim was added on purpose. The `--glossary` flag and command surface are unchanged.
62
+
63
+ ### Headline behavior change — replace mode for top-level `theme.Window` / `View` / `ImageView`
64
+
65
+ Before v7.9.0, `theme.Window` (no `extend`) still merged with the framework defaults (white `backgroundColor`, `Ti.UI.SIZE` on `View`, iOS `hires: true` on `ImageView`), which produced gradient ghosting and similar overrides. v7.9.0 makes top-level configs behave as true **replace mode**.
66
+
67
+ If you previously wrote:
68
+
69
+ ```javascript
70
+ theme: {
71
+ Window: {
72
+ apply: 'bg-gradient-to-b from-blue-500 to-purple-600'
73
+ }
74
+ }
75
+ ```
76
+
77
+ …and **depended** on the implicit white background, the gradient now renders without that background underneath. Move the config under `theme.extend.Window` to keep the merged behavior, or add the previously-implicit utilities back into the `apply` string. See [`apply-directive.md` → Extend mode vs replace mode](./apply-directive.md#extend-mode-vs-replace-mode).
78
+
79
+ ### Added in v7.9.0
80
+
81
+ - **Opacity modifiers on semantic colors** — `bg-surface/65` now works for any class mapped through `theme.extend.colors`. PurgeTSS auto-derives `<originalKey>_<alphaPercent>` entries in `semantic.colors.json` per mode (light/dark). **Native rebuild required** — Liveview hot-reload alone does not refresh `semantic.colors.json`. See [`semantic-colors.md`](./semantic-colors.md#opacity-modifier-auto-derivation).
82
+
83
+ ### Fixed in v7.9.0
84
+
85
+ - Several fixes around semantic colors, gradients, and Ti Element defaults: tonal palette no longer inverts Light and Dark; gradient `from` / `to` color order is position-stable across `sort()`; `bg-gradient-to-X` direction is preserved when combined with `from-X to-Y` in the same `apply`; `theme.Window` / `theme.View` / `theme.ImageView` no longer ghost framework presets at the top level (see Headline behavior change above).
86
+
87
+ ---
88
+
89
+ ## Upgrade to v7.8.0
90
+
91
+ v7.8.0 introduces a structured `Class Syntax Error` block that **halts the build** when it detects known class-name mistakes — previously these flowed silently into the `// Unused or unsupported classes` block of `app.tss`.
92
+
93
+ ### Added — Class Syntax Error pre-validation
94
+
95
+ Five patterns are now caught and reported with file + line + suggested fix:
96
+
97
+ | Pattern | Offending input | Fix |
98
+ | --- | --- | --- |
99
+ | Inverted negative sign | `top-(-10)` | `-top-(10)` |
100
+ | Square-bracket notation | `top-[10px]` | `top-(10px)` |
101
+ | Empty parentheses | `wh-()` | (flagged, no auto-fix) |
102
+ | Whitespace inside parentheses | `wh-( 200 )` | `wh-(200)` |
103
+ | Redundant `px` unit | `top-(10px)` | `top-(10)` |
104
+
105
+ All offenders are reported in a single run. Generic unknown classes — typos, vendor utilities not enabled, custom classes not declared yet — continue to flow into `// Unused or unsupported classes`. See [`arbitrary-values.md` → Class syntax pre-validation](./arbitrary-values.md#class-syntax-pre-validation).
106
+
107
+ ### Added — `purgetss images --width <n>` (v7.8.0)
108
+
109
+ Pins Android `mdpi` (= iPhone `@1x`) to `<n>` pixels wide. Larger scales derive as ×1.5, ×2, ×3, ×4 from that base. Range `[1, 8192]`. Most useful for SVG sources from vector editors (Affinity, Illustrator) with disproportionate viewBoxes. CLI-only — width is per-asset, not a project-wide setting. See [`multi-density-images.md`](./multi-density-images.md#pinning-the-output-width-with---width).
110
+
111
+ ### Fixed in v7.8.0
112
+
113
+ - The arbitrary-value parser no longer crashes on negative values inside parentheses — `top-(-10)` is now recognized and reported as an inverted-negative-sign error instead of triggering a `Cannot read properties of null (reading 'pop')` exception.
114
+
115
+ ### What to review
116
+
117
+ - Run the build once on the upgraded version and address every `Class Syntax Error` it surfaces. The offender list is exhaustive in one pass.
118
+ - If a CI step depended on a malformed class quietly landing in the unused-classes block, it will now hard-fail — adjust the CI accordingly.
119
+
120
+ ---
121
+
122
+ ## Upgrade to v7.7.0
123
+
124
+ v7.7.0 cleans up the `brand:` config before stabilizing it. **Pre-7.10.2** projects on the flat schema crashed; from v7.10.2 onward the flat schema auto-migrates in memory (see Upgrade to v7.10.x). The recommended migration is still a one-time update to the grouped schema.
125
+
126
+ ### Restructure — grouped `brand:` config
127
+
128
+ Branding settings moved out of flat keys into purpose-based groups: `brand.logos`, `brand.padding`, `brand.android`, `brand.ios`, `brand.colors`.
129
+
130
+ ```javascript
131
+ // Pre-7.7.0 — flat
132
+ brand: {
133
+ padding: 15,
134
+ iosPadding: 4,
135
+ bgColor: '#FFFFFF',
136
+ notification: false,
137
+ splash: false
138
+ }
139
+
140
+ // v7.7.0+ — grouped
141
+ brand: {
142
+ padding: {
143
+ ios: '4%',
144
+ androidLegacy: '10%',
145
+ androidAdaptive: '19%'
146
+ },
147
+ android: {
148
+ notification: false,
149
+ splash: false
150
+ },
151
+ colors: {
152
+ background: '#FFFFFF'
153
+ }
154
+ }
155
+ ```
156
+
157
+ ### Added in v7.7.0
158
+
159
+ - **Separate Android brand inputs** — `logos.androidLauncher` / `--icon-logo` for the Android launcher icon; `logos.androidSplash` / `--splash-logo` for Android 12+ splash artwork. Drop `logo-icon.*` / `logo-splash.*` into `purgetss/brand/` for auto-discovery.
160
+ - **Independent Android paddings** — `--android-adaptive-padding` (default `19%`) and `--android-legacy-padding` (default `10%`) replace the single `--padding`. `--padding` is now a shortcut that sets both for one run (note: the shortcut bug where only `androidAdaptive` was applied was fixed in v7.10.0).
161
+ - **Android splash fallback regenerated** — `app/assets/android/default.png` (Alloy) or `Resources/android/default.png` (Classic). `cleanup-legacy` no longer removes `default.png`.
162
+ - **Values and Units doc** — new official reference explaining how `ti.ui.defaultunit` in `tiapp.xml` interprets PurgeTSS unitless values. See [`values-and-units.md`](./values-and-units.md).
163
+
164
+ ---
165
+
9
166
  ## Upgrade to v7.6.0
10
167
 
11
168
  v7.6.0 introduces three new CLI commands for app-asset generation plus two new `config.cjs` sections. None of the additions are breaking — existing projects continue to work untouched, and the new config sections are auto-injected on first run.
@@ -211,3 +368,7 @@ If you previously worked around this by inlining the gradient directly in TSS, r
211
368
  - After v7.5.0: diff generated `utilities.tss` to confirm property deduplication produces the expected output.
212
369
  - After v7.5.3: consider wiring `Appearance.init()` at app boot if you want runtime Light/Dark switching.
213
370
  - After v7.6.0: run `brand`, `images`, and `semantic` once in a scratch project before pointing them at production assets, so you can preview the output layout.
371
+ - After v7.7.0: migrate the `brand:` block in `config.cjs` to the grouped schema (`logos`, `padding`, `android`, `ios`, `colors`). v7.10.2 auto-migrates flat configs in memory, but the one-time update is recommended to silence the deprecation notice.
372
+ - After v7.8.0: run the build once and address every `Class Syntax Error` it surfaces. Update CI to handle the new hard-fail on malformed class names. Migrate any `top-[10px]` style square brackets to `top-(10px)` parentheses.
373
+ - After v7.9.0: search for any `purgetss/experimental/tailwind-classes/` references in tooling/CI and update to `purgetss/glossary/tailwind-classes/`. If a project used top-level `theme.Window` / `View` / `ImageView` and depended on framework defaults being merged in, decide between moving the config under `theme.extend.*` or adding the previously-implicit utilities to the `apply` string.
374
+ - After v7.10.0: deeply nested color families (`theme.extend.colors.brand.primary.500`) now emit recursively — restructure by domain if it improves readability. `apply:` with bundled icon fonts (`fas`, `mi-*`, `ms-*`, `f7-*`) no longer requires `build-fonts` first. The Google Play Feature Graphic ships automatically with `purgetss brand`.