You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Released of version 0.2.0
See below the full CHANGELOG details.
Added:
- [Tests] Add UI regression tests using snapshot comparisons with *swift-snapshot-testing* tool ([#78](#78))
- [DemoApp] Display fake components for elevation rendering tests
- [Library] A theme can now override the custom font family
- [Tests] Add more unit tests for theme overriding and raw tokens controls
- [Library] Add and update raw and semantic grid tokens ([#40](#40))
- [Library] Manage regular and compact layouts for sizing and spacing tokens
- [Library] "Box shadow 0" has been defined and "elevation drag" changed
- [Doc] Create the basics of a documentation ([#9](#9))
- [Library] Add more semanttic and raw tokens for typography
- [Library] Add more semantic and raw tokens for typography, and SwiftUI API to apply them
- [Library] Computation of SwiftUI radius from Figma blur and spread values for elevation tokens
- [Library] Add elevation tokens ([#32](#32))
Changed:
- [Library] Split raws, semantics and components tokens definitions and also values, composites and type aliases
- [Showcase] Improve Fastlane alpha build notifications
- [Library] Do not store blur value in elevation semantic tokens
- [Library] Change type aliases for X and Y offsets of elevations tokens
- [Library] Update border semantic tokens values ([#106](#106))
- [Showcase] Add fake components for demo and tokens tests
- [Library] Remove spread value for elevation tokens
- [Library] Remove paragraph spacing tokens for typography
- [Library] Term "fluid" has been replaced by "adaptable" in spacing semantic tokens
- [Doc] Improve DocC documentation about tokens and views extensions
- [Doc] Add more details in release documentation
- [Library] Rename semantic token "opacityEmphasized" to "opacityStrong" ([#94](#94))
- [Library] Update value of opacity raw token "opacity800" from 0.88 to 0.80 ([#87](#87))
- [Tests] Add missing unit tests for opacity raw tokens
- [Library] "OUDSThemesCommons" product has been renamed to "OUDS"
Removed:
- [Library] Remove Z Index tokens for elevations ([#109](#109))
- [Library] Remove token "borderRadiusPill" and "borderRadiusCircle" ([#58](#58))
- [Library] "Emphasis" words have been replaced by "emphasized"
- [Library] "Box shadow" words have been removed in elevation semantic and raw tokens
Fixed:
- [Library] Fix some typos in documentation ([#89](#89))
Acked-by: Ludovic Pinel <[email protected]>
Co-authored-by: Ludovic Pinel <[email protected]>
Co-authored-by: Pierre-Yves Lapersonne <[email protected]>
Co-authored-by: Julien Déramond <[email protected]>
*[Unit tests for OUDS Swift package](#unit-tests-for-ouds-swift-package)
8
+
*[UI tests in demo app](#ui-tests-in-demo-app)
6
9
-[Build phases](#build-phases)
7
10
-[Targets](#targets)
8
11
-[Certificates, profiles and identifiers](#certificates-profiles-and-identifiers)
@@ -20,12 +23,12 @@
20
23
You should check wether or not you have the tools in use in the project like _Fastlane_, _SwiftLint_, _SwiftFormat_, etc.
21
24
You can have a look for example in thr **THIRD\_PARTY.md** file which lists any dependencies and tools we use are different levels (SDK, showcase app, projects).
22
25
23
-
If some tools are missing, pick the suitable command line bellow:
26
+
If some tools are missing, pick the suitable command line below:
24
27
```bash
25
28
# Use Bundler to install a major part of dependencies (thanks to Gemfile and Gemfile.lock files)
26
29
bundle install
27
30
28
-
# Use CocoaPods to install other dependencies not avaialble as rubygems (thanks to Podfile and Podfile.lock files)
31
+
# Use CocoaPods to install other dependencies not available as rubygems (thanks to Podfile and Podfile.lock files)
29
32
bundle exec pod install
30
33
31
34
# Some dependencies must be downloaded by hand:
@@ -49,7 +52,53 @@ To build the demo application follow those steps:
49
52
50
53
## Documentation
51
54
52
-
_To be defined soon_
55
+
The documentation is based on the Swift documentation with [DocC](https://www.swift.org/documentation/docc/).
56
+
We use here the [swift-docc-plugin](https://github.com/swiftlang/swift-docc-plugin) to build the HTML documentations using the documentation catalogs
57
+
and any _DocC_ comments in the source code.
58
+
59
+
The documentation can be built from Xcode with _Product > Build Documentation_.
60
+
61
+
The `generateDoc.sh` script helps to build the HTML version of documentation and compress it in ZIP file, and also can update
62
+
the online version based on [_GitHub Pages_](https://pages.github.com/), this version is hosted in the [*gh-pages* GitHub branch](https://github.com/Orange-OpenSource/ouds-ios/tree/gh-pages).
63
+
64
+
## Run tests
65
+
66
+
### Unit tests for OUDS Swift package
67
+
68
+
To run these unit tests follow some steps:
69
+
70
+
1.`cd Showcase`
71
+
2.`bundle exec pod install`
72
+
3. Open *Showcase.xcworkspace*
73
+
4. Select *Showcase* scheme
74
+
5. Run tests (Product -> Test)
75
+
76
+
Unit tests care have been implemented for several reasons.
77
+
78
+
First, we don't have too much control on the raw tokens values. We rely on the _Figma_ design tool which outputs the tokens in a JSON file.
79
+
And this file will be parsed to as to generate Swift files. But if there are inconsistencies in the _Figma_ side or in the parser side, the inconsistencies will be spread in our code base.
80
+
It is not useful to define unit tests for raw tokens to test their values ; in fact they exist here to be updated.
81
+
But we wan still check other things like the relationship between them. For example a _grid100_ should always be less or equal than a _grid100_. Some _color100_ should be always lighter than a _color200_, etc, etc. A small typo should be always smaller or with the sale size has a one-step-bigger typo.
82
+
83
+
Then, we want to know when tokens have been removed so as to warn our users and keep release notes and changelog clean. If we don't spot such changes, maybe some users will be impacted.
84
+
85
+
Finally, we ensure our themes can override any semantic tokens. Themes are in fact a set of values for the whole universe of semantic tokens, and if a theme cannot override a semantic token, there could be an issue. Unit tests also help us to find if some tokens have been removed before releasing the library.
86
+
87
+
### UI tests in demo app
88
+
89
+
To run these UI tests follow some steps:
90
+
91
+
1.`cd Showcase`
92
+
2.`bundle exec pod install`
93
+
3. Open *Showcase.xcworkspace*
94
+
4. Select *ShowcaseTests* scheme
95
+
5. Select some simulator (tests designed for *iPhone 13 Pro Max* and *iPhone 14 Pro Max* but works elsewhere)
96
+
6. Run tests (Product -> Test)
97
+
98
+
Beware, if you add new UI tests using [swift-snapshot-testing](https://github.com/pointfreeco/swift-snapshot-testing) library, you may have new tests which fail at first time.
99
+
Indeed for new tests the tool makes snapshots of the views, thus for the first run no preview exist making the tests fail. You should run the tests twice for new tests.
100
+
101
+
Such tests here are used to as to be sure the look and feel of any components and tokens rendering remaing the expected ones.
53
102
54
103
## Build phases
55
104
@@ -65,11 +114,12 @@ The Xcode project contains two targets:
65
114
66
115
1._Showcase_ for the demo application
67
116
2._Periphery_ to look for dead code in the source code
117
+
3._ShowcaseTests_ for UI tests in demo app
68
118
69
119
## Certificates, profiles and identifiers
70
120
71
121
We choose to use Xcode automatic signing for debug builds of the app so as to make easier onboarding of newcomers in development team, and also to prevent to update provisioning profiles with individual developers certificates each team someone wants to build the app and also to prevent to register each new build device). You may need to be part of our team if you want to build in debug mode.
72
-
Note the bundle identifier here for lcoal builds is **com.orange.ouds.demoapp-debug**, with a **-debug** suffix so as to prevent any local build to be replaced by TestFlight builds which have **com.orange.ouds.demoapp** identifiers.
122
+
Note the bundle identifier here for local builds is **com.orange.ouds.demoapp-debug**, with a **-debug** suffix so as to prevent any local build to be replaced by TestFlight builds which have **com.orange.ouds.demoapp** identifiers.
73
123
74
124
However for release builds we use a dedicated _provisioning profile_ built with of course a _distribution certificate_(.p12 format with private key, not .cer) and the _bundle identifier_`com.orange.ouds.demoapp` for our _Apple Team_`France Telecom (MG2LSJNJB6)`. Thus you won't be able to build and sign in release mode without this provisioning profile and this distribution certificate. These elements are stored in our local GitLab CI runners and must not be available outside.
75
125
@@ -166,7 +216,7 @@ exit 0
166
216
We try also to apply [keep a changelog](https://keepachangelog.com/en/1.0.0/), and [semantic versioning](https://semver.org/spec/v2.0.0.html) both with [conventional commits](https://www.conventionalcommits.org/en/v1.0.0/).
167
217
168
218
You can generate a `RELEASE_NOTE.md` file using your Git history and [git cliff](https://git-cliff.org/) tool.
169
-
Define first a `cliff.toml` configuration file containing the code bellow.
219
+
Define first a `cliff.toml` configuration file containing the code below.
170
220
171
221
```toml
172
222
# git-cliff ~ configuration file
@@ -176,7 +226,7 @@ Define first a `cliff.toml` configuration file containing the code bellow.
176
226
# changelog header
177
227
header = """
178
228
# Release Note\n
179
-
All notable changes for this version are here and blablbla.\n
229
+
All notable changes for this version are here and blablabla.\n
180
230
"""
181
231
# template for the changelog body
182
232
# https://keats.github.io/tera/docs/#introduction
@@ -353,9 +403,9 @@ sort_commits = "oldest"
353
403
A [GitHub Action](https://github.com/gitleaks/gitleaks-action) has been integrated to the repository with a configuration file defined in _/github/workflows_ named _gitleaks-action.yaml_.
354
404
It will launch the _Gitleaks_ tool automatically.
355
405
356
-
Howevere this tool does not detect plain API key mixed in URL, that is a reason why _Gitleaks_ can be called in a pre-commit hook, using the _giteaks.toml_ at the root of the prokect.
406
+
However this tool does not detect plain API key mixed in URL, that is a reason why _Gitleaks_ can be called in a pre-commit hook, using the _giteaks.toml_ at the root of the project.
357
407
To call _Gitleaks_ in pre-commit hooks, create a file named **pre-commit** inside _.git/hooks_ (then run `chmod u+x` in the file).
-[Showcase] Add fake components for demo and tokens tests
32
+
-[Library] Remove spread value for elevation tokens
33
+
-[Library] Remove paragraph spacing tokens for typography
34
+
-[Library] Term "fluid" has been replaced by "adaptable" in spacing semantic tokens
35
+
-[Doc] Improve DocC documentation about tokens and views extensions
36
+
-[Doc] Add more details in release documentation
37
+
-[Library] Rename semantic token "opacityEmphasized" to "opacityStrong" ([#94](https://github.com/Orange-OpenSource/ouds-ios/issues/94))
38
+
-[Library] Update value of opacity raw token "opacity800" from 0.88 to 0.80 ([#87](https://github.com/Orange-OpenSource/ouds-ios/issues/87))
39
+
-[Tests] Add missing unit tests for opacity raw tokens
40
+
-[Library] "OUDSThemesCommons" product has been renamed to "OUDS"
41
+
42
+
### Removed
43
+
44
+
-[Library] Remove Z Index tokens for elevations ([#109](https://github.com/Orange-OpenSource/ouds-ios/issues/109))
45
+
-[Library] Remove token "borderRadiusPill" and "borderRadiusCircle" ([#58](https://github.com/Orange-OpenSource/ouds-ios/issues/58))
46
+
-[Library] "Emphasis" words have been replaced by "emphasized"
47
+
-[Library] "Box shadow" words have been removed in elevation semantic and raw tokens
48
+
49
+
### Fixed
50
+
51
+
-[Library] Fix some typos in documentation ([#89](https://github.com/Orange-OpenSource/ouds-ios/issues/89))
-[Library] Add unit tests for Sosh brand colors raw tokens
13
-
-[Library] Add unit tests for Orange brand colors raw tokens
14
-
-[Library] Add unit tests for foundations
15
-
-[Library] Add unit tests for raw tokens and semantic tokens for colors
58
+
-[Tests] Add unit tests for Sosh brand colors raw tokens
59
+
-[Tests] Add unit tests for Orange brand colors raw tokens
60
+
-[Tests] Add unit tests for foundations
61
+
-[Tests] Add unit tests for raw tokens and semantic tokens for colors
16
62
-[Library] Add draft of raw tokens and semantic tokens for grids
17
63
18
64
### Changed
19
65
20
66
-[Library] Redefine Swift Package with clearer path for sources, tests cases and test plan
21
67
-[Library] Expose product "OUDSThemesCommons" instead of "OUDSThemesShared"
22
-
-[Library] Improve unit tests for elevation semantic tokens
23
-
-[Library] Improve unit tests for typography raw tokens
24
-
-[Library] Improve unit tests for opacity raw tokens
25
-
-[Library] Improve unit tests for elevations raw tokens
26
-
-[Library] Improve unit tests for dimensions raw tokens
27
-
-[Library] Improve unit tests for borders raw tokens
68
+
-[Tests] Improve unit tests for elevation semantic tokens
69
+
-[Tests] Improve unit tests for typography raw tokens
70
+
-[Tests] Improve unit tests for opacity raw tokens
71
+
-[Tests] Improve unit tests for elevations raw tokens
72
+
-[Tests] Improve unit tests for dimensions raw tokens
73
+
-[Tests] Improve unit tests for borders raw tokens
28
74
29
75
### Fixed
30
76
@@ -43,7 +89,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
43
89
-[Library] Add raw tokens and semantic tokens for border ([#30](https://github.com/Orange-OpenSource/ouds-ios/issues/30))
44
90
-[Library] Define Swift Package architecture of library and tokens (raw and semantic) ([#33](https://github.com/Orange-OpenSource/ouds-ios/issues/33))
45
91
-[Library] Define Swift Package library for OUDS ([#46](https://github.com/Orange-OpenSource/ouds-ios/issues/46))
46
-
47
92
-[Showcase] Publication of comment on issues about new alpha build upload on TestFlight ([#56](https://github.com/Orange-OpenSource/ouds-ios/issues/56))
48
93
-[Showcase] Distribute demo app development version ([#12](https://github.com/Orange-OpenSource/ouds-ios/issues/12))
49
94
-[Showcase] Distribute demo app for feature validation ([#13](https://github.com/Orange-OpenSource/ouds-ios/issues/13))
0 commit comments