Skip to content

Commit

Permalink
Release 0.16.0 (#604)
Browse files Browse the repository at this point in the history
* Prepare new 0.16.0 version (#534)

* [#540] Remove useless badge in README (#541)

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* [#537] App News improvements (#539)

* fix(#537): corrupted AppNews.sjon file

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* chore(#537): clean up

- Remove useless method
- Better decoration

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* refactor(#537): use view model, laoding states and errors for about module

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* chore(#537): replace ... characters by elipsis unicode code

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* feat(#537): add new cache for data formatter with using date format

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* refactor(#537): use cached date formatter to format date in app news

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* fix(Podfile): version of CocoaPods in Podfile.lock

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* chore(#573): refactor logger

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* chore(#537): add logs in App News resource loading

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* test(#537): unit tests for AppNewsListViewModel

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* feat(#573): add script phase to check in Xcode AppNews.json files

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* style: applied linter autoformat

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* chore: update CHANGELOG

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* feat(#537): store in cache the AppNews instead of reading from file each time

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* refactor(#537): apply review comments

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* chore(#537): update logger and developer documentation about targets and build phases

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

---------

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>

* Fix adding title in navigation bar (#550)

Reviewed-by: Pierre-Yves Lapersonne <[email protected]>

* [547] Accessibility - Group texts in cards for VoiceOver (#551)

* Fix bug and update changelog

* Update changelog

Reviewed-by: Pierre-Yves Lapersonne <[email protected]>

* [#542] Update guidelines typography names (#552)

* Update names and changelog

* review: uprdate description for labelS

Reviewed-by: Pierre-Yves Lapersonne <[email protected]>

* [#262] Refactor chips API (#548)

* Create choice chips

* Add action chips

* Rafactor chip API (action, filter, choice)

* Picker chip container

* Add desciption for chips variant

* Remove ODSChipPicker

* Add documentation

* review: remove unused file

* Update build phases

* review: fix all remarks

* Use new Typography style for chips

* review: fix remarks

Reviewed-by: Pierre-Yves Lapersonne <[email protected]>
Tested-by: Pierre-Yves Lapersonne <[email protected]>

* [#553] Refactor variant page and entry (#556)

* Rename Component and guidlines title to name + refactor variant view

* Updat changelog

* review: update wrong code

Reviewed-by: Pierre-Yves Lapersonne <[email protected]>

* [#546] Remove accessibility labels and associated wording keys (#566)

Reviewed-by: Pierre-Yves Lapersonne <[email protected]>

* [#562] Back button renamed after switching from lanscape to portrait mode #576

Reviewed-by: Pierre-Yves Lapersonne <[email protected]>
Tested-by: Pierre-Yves Lapersonne <[email protected]>

* [#499] Thumbnail of card vertical header first not showing (#579)

* Upodate CardHeaderFirst API to set Image source as thumbnail

* Update docs for cards

* Update changelog file

* review: fix mistakes in doc

Reviewed-by: Pierre-Yves Lapersonne <[email protected]>
Tested-by: Pierre-Yves Lapersonne <[email protected]>

* Add missing issue in changelog

* [#594] Size of filter chips is not inconsistent in selected and unselected states (#599)

* Fix the minimum sze of the text

* Mistakes in changelog

Reviewed-by: Pierre-Yves Lapersonne <[email protected]>
Tested-by: Pierre-Yves Lapersonne <[email protected]>

* [#577] Options are overlapped in Setup page of the about module (#592)

* Update Choice and Filter chips pickers

* Reorder lines in changelog

* review: fix mistakes in changelog and fix extra paddings

* Adjust paddings

Tested-by: Pierre-Yves Lapersonne <[email protected]>
Reviewed-by: Pierre-Yves Lapersonne <[email protected]>

* Prepare release 0.16.0 (#603)

* Update changelog and Appnews files

---------

Signed-off-by: Pierre-Yves Lapersonne <[email protected]>
Co-authored-by: Pierre-Yves Lapersonne <[email protected]>
  • Loading branch information
ludovic35 and pylapp authored Jan 15, 2024
1 parent 40c60cc commit cda78da
Show file tree
Hide file tree
Showing 160 changed files with 3,494 additions and 1,986 deletions.
57 changes: 37 additions & 20 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,31 +3,48 @@
All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](http://semver.org/).

## [0.16.0]\(https://github.com/Orange-OpenSource/ods-ios/compare/0.16.0...0.15.0) - 2024-01-15

- [SDK/DemoApp] Options are overlapped in Setup page of the about module. This needs update in Chips Pickers (Bug [#577] (https://github.com/Orange-OpenSource/ods-ios/issues/577))
- [SDK] Size of filter chips is not inconsistent in selected and unselected states (Bug [#594](https://github.com/Orange-OpenSource/ods-ios/issues/594))
- [DemoApp/SDK] Thumbnail of card vertical header first not showing (Bug [#499](https://github.com/Orange-OpenSource/ods-ios/issues/499))
- [DemoApp] Back button renamed after switching from lanscape to portrait mode (Bug [#562](https://github.com/Orange-OpenSource/ods-ios/issues/562))
- [DemoApp] Udpate accessibility label on Functional and Emphasis buttons in demo app ([#546](https://github.com/Orange-OpenSource/ods-ios/issues/546))
- [SDK/DemoApp] Refactor chips component API ([#262](https://github.com/Orange-OpenSource/ods-ios/issues/262))
- [SDK] Update guidelines typography names ([#542](https://github.com/Orange-OpenSource/ods-ios/issues/542))
- [DemoApp] Refactor variant page and entry ([#553](https://github.com/Orange-OpenSource/ods-ios/issues/553))
- [SDK] Accessibility - Group texts in cards for VoiceOver (Bug [#547](https://github.com/Orange-OpenSource/ods-ios/issues/547))
- [DemoApp] No title on Component - Lists - Standard and Selection screens (Bug [#545](https://github.com/Orange-OpenSource/ods-ios/issues/545))
- [Tooling] Add script phase to check if AppNews.json files are conform to JSON format
- [DemoApp/SDK] Refactor About module (with view model, errors management and unit tests)
- [DemoApp/SDK] Change wording by replacing ... by elipsis code
- [DemoApp] Fix corrupted AppNews.json file

## [0.15.0](https://github.com/Orange-OpenSource/ods-ios/compare/0.15.0...0.14.0) - 2023-11-14

- [DemoApp/SDK] Fix compilation issues (auto signing for release, remove ios 17 support) [#529](https://github.com/Orange-OpenSource/ods-ios/issues/529))
- [DemoApp] Review the naming of the wording keys for components [#523](https://github.com/Orange-OpenSource/ods-ios/issues/523))
- [DemoApp] Show List style and Header and Footer of Sections [#416](https://github.com/Orange-OpenSource/ods-ios/issues/416))
- [Tooling] Add doctor script to check if project preconditions are filled and update README[#516](https://github.com/Orange-OpenSource/ods-ios/issues/516)
- [DemoApp/SDK/Tooling] Add new Swiftlint rules and remove some warnings for cleaner source code [#514](https://github.com/Orange-OpenSource/ods-ios/issues/514)
- [DemoApp] Remove dead code from app with Periphery [#511](https://github.com/Orange-OpenSource/ods-ios/issues/511)
- [DemoApp/SDK/Tooling] Update source files headers to be compliant with SPDX format [#497](https://github.com/Orange-OpenSource/ods-ios/issues/497)
- [Tooling] Run tests plan in CI/CD chain [#506](https://github.com/Orange-OpenSource/ods-ios/issues/506)
- [Tooling] Add Mattermost notifications for build and upload lanes [#503](https://github.com/Orange-OpenSource/ods-ios/issues/503)
- [Tooling] Downgrade version of activesupport (Cocoapods issue, CI/CD troubleshooting) [#501](https://github.com/Orange-OpenSource/ods-ios/issues/501)
- [SDK] Internationalization support [#466](https://github.com/Orange-OpenSource/ods-ios/issues/466))
- [Tooling] Fix security issues with activesupport transitive dependency (cocoapods gem) [#495](https://github.com/Orange-OpenSource/ods-ios/issues/495)
- [DemoApp/SDK] Update ListItem api to use SwiftUI elements [#462](https://github.com/Orange-OpenSource/ods-ios/issues/462))
- [DemoApp/SDK] Add accessibility statement in About module [#119](https://github.com/Orange-OpenSource/ods-ios/issues/119))
- [SDK] Update CardSmall api to use SwiftUI elements [#485](https://github.com/Orange-OpenSource/ods-ios/issues/485))
- [DemoApp/SDK] Fix compilation issues (auto signing for release, remove ios 17 support) ([#529](https://github.com/Orange-OpenSource/ods-ios/issues/529))
- [DemoApp] Review the naming of the wording keys for components ([#523](https://github.com/Orange-OpenSource/ods-ios/issues/523))
- [DemoApp] Show List style and Header and Footer of Sections ([#416](https://github.com/Orange-OpenSource/ods-ios/issues/416))
- [Tooling] Add doctor script to check if project preconditions are filled and update README ([#516](https://github.com/Orange-OpenSource/ods-ios/issues/516))
- [DemoApp/SDK/Tooling] Add new Swiftlint rules and remove some warnings for cleaner source code ([#514](https://github.com/Orange-OpenSource/ods-ios/issues/514))
- [DemoApp] Remove dead code from app with Periphery ([#511](https://github.com/Orange-OpenSource/ods-ios/issues/511))
- [DemoApp/SDK/Tooling] Update source files headers to be compliant with SPDX format ([#497](https://github.com/Orange-OpenSource/ods-ios/issues/497))
- [Tooling] Run tests plan in CI/CD chain ([#506](https://github.com/Orange-OpenSource/ods-ios/issues/506))
- [Tooling] Add Mattermost notifications for build and upload lanes ([#503](https://github.com/Orange-OpenSource/ods-ios/issues/503))
- [Tooling] Downgrade version of activesupport (Cocoapods issue, CI/CD troubleshooting) ([#501](https://github.com/Orange-OpenSource/ods-ios/issues/501))
- [SDK] Internationalization support ([#466](https://github.com/Orange-OpenSource/ods-ios/issues/466))
- [Tooling] Fix security issues with activesupport transitive dependency (cocoapods gem) ([#495](https://github.com/Orange-OpenSource/ods-ios/issues/495)
- [DemoApp/SDK] Update ListItem api to use SwiftUI elements ([#462](https://github.com/Orange-OpenSource/ods-ios/issues/462))
- [DemoApp/SDK] Add accessibility statement in About module ([#119](https://github.com/Orange-OpenSource/ods-ios/issues/119))
- [SDK] Update CardSmall api to use SwiftUI elements ([#485](https://github.com/Orange-OpenSource/ods-ios/issues/485))

## [0.14.0](https://github.com/Orange-OpenSource/ods-ios/compare/0.14.0...0.13.1) - 2023-10-09

- [SDK] Update CardVerticalImageFirst api to use SwiftUI elements [#481](https://github.com/Orange-OpenSource/ods-ios/issues/481))
- [SDK] Update CardVerticalHeaderFirst api to use SwiftUI elements [#479](https://github.com/Orange-OpenSource/ods-ios/issues/479))
- [SDK] Update CardHorizontal api to use SwiftUI elements [#477](https://github.com/Orange-OpenSource/ods-ios/issues/477))
- [SDK] Update Button api to use SwiftUI elements and use a buttonStyle [#471](https://github.com/Orange-OpenSource/ods-ios/issues/471))
- [SDK] Update banner api to use SwiftUI elements [#473](https://github.com/Orange-OpenSource/ods-ios/issues/473))
- [SDK] Update CardVerticalImageFirst api to use SwiftUI elements ([#481](https://github.com/Orange-OpenSource/ods-ios/issues/481))
- [SDK] Update CardVerticalHeaderFirst api to use SwiftUI elements ([#479](https://github.com/Orange-OpenSource/ods-ios/issues/479))
- [SDK] Update CardHorizontal api to use SwiftUI elements ([#477](https://github.com/Orange-OpenSource/ods-ios/issues/477))
- [SDK] Update Button api to use SwiftUI elements and use a buttonStyle ([#471](https://github.com/Orange-OpenSource/ods-ios/issues/471))
- [SDK] Update banner api to use SwiftUI elements ([#473](https://github.com/Orange-OpenSource/ods-ios/issues/473))
- [SDK] Accessibility Voice over - Application name is a header in the about screen (Bug [#468](https://github.com/Orange-OpenSource/ods-ios/issues/468))
- [DemoApp/SDK] Update the button emphasis scale naming ([#464](https://github.com/Orange-OpenSource/ods-ios/issues/464))
- [DemoApp] Update configuration to display by default buttons in variable width and without icon ([#459](https://github.com/Orange-OpenSource/ods-ios/issues/459))
Expand Down
55 changes: 55 additions & 0 deletions DEVELOP.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,58 @@ Execute the commands below to generate and run the documentation:
If you encounter errors during installation and your platform is not listed in the `PLATFORMS` section of `Gemfile.lock`, you can optionally run `bundle platform` to retrieve your platform, then `bundle lock --add-platform <your_platform>` to install specific dependencies for your platform.

Finally, open your browser and go to http://127.0.0.1:4000/ods-ios/

## Build phases

The project contains several custom build phases so as to automatize several steps:

1. _SwiftFormat (headers of sources)_ format the source code files headers with a template
2. _SwiftLint_ will run the linter on the sources
3. _Check JSON files format_ will run a Shell command to check wether or not the AppNews JSON files are compliant JSON files or not

## Targets

The Xcode project contains three targets:

1. _OrangeDesignSystemDemo_ for the application
2. _OoangeDesignSystemDemoTests_ for the unit tests targeting the library
3. _Periphery (dead code finder)_ to look for dead code in the source code

## JSON file validations

Some JSON files are used in the application like the _AppNews.json_.
You can check its integrity and if all the fields are well defined by using its JSON schema:

```json
// Can be stored in a schema.json file for further tests
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://github.com/Orange-OpenSource/ods-ios/schema/AppNews",
"title": "App News",
"description": "The catalog of app news with date, versions and news",
"items": {
"type": "object",
"properties": {
"version": {
"description": "The version of the app with these news, matching the releases",
"type": "string"
},
"date": {
"description": "The date in yyyy-MM-dd format",
"type": "string"
},
"news": {
"description": "The main news of the app",
"type": "string"
}
}
},
"required": [ "version", "date", "news" ]
}
```

Then you can run the following command bellow to check if the _AppNews.json_ file matches the specification of the schema:

```shell
check-jsonschema --schemafile schema.json AppNews.json
```
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public struct ODSBanner: View {
}

text
.odsFont(.subhead)
.odsFont(.bodyS)
.frame(maxWidth: .infinity, alignment: .leading)
}
.padding(.top, ODSSpacing.m)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,18 +36,18 @@ struct BottomSheedHeader: View {
icon?
.foregroundColor(.primary)
.accessibility(hidden: true)
.odsFont(.headline)
.odsFont(.headlineS)
.animation(.linear, value: applyRotation)
.rotationEffect(.degrees(applyRotation ? 180 : 0))

VStack(alignment: .leading, spacing: ODSSpacing.none) {
Text(title)
.odsFont(.headline)
.odsFont(.headlineS)
.frame(maxWidth: .infinity, alignment: .leading)

if let subtitle = self.subtitle {
Text(subtitle)
.odsFont(.subhead)
.odsFont(.bodyS)
.frame(maxWidth: .infinity, alignment: .leading)
}
}
Expand Down Expand Up @@ -92,28 +92,28 @@ struct HeaderPreviewProvider_Previews: PreviewProvider {
VStack(spacing: 50) {
VStack {
Text("Title and Subtile")
.odsFont(.title2)
.odsFont(.titleM)
.frame(maxWidth: .infinity, alignment: .leading)
BottomSheedHeader(title: "Title", subtitle: "Subtitle", icon: nil, applyRotation: false)
}

VStack {
Text("Title and icon (without rotation)")
.odsFont(.title2)
.odsFont(.titleM)
.frame(maxWidth: .infinity, alignment: .leading)
BottomSheedHeader(title: "Title", subtitle: nil, icon: Image(systemName: "chevron.down"), applyRotation: false)
}

VStack {
Text("Title and icon (with rotation)")
.odsFont(.title2)
.odsFont(.titleM)
.frame(maxWidth: .infinity, alignment: .leading)
BottomSheedHeader(title: "Title", subtitle: nil, icon: Image(systemName: "chevron.down"), applyRotation: true)
}

VStack {
Text("Title and icon (animated rotation)")
.odsFont(.title2)
.odsFont(.titleM)
.frame(maxWidth: .infinity, alignment: .leading)
AnimatinoExample()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ struct ODSBottomSheetExpandingModifier<ContentView>: ViewModifier where ContentV
content
.bottomSheet(
bottomSheetPosition: $bottomSheetPosition,
switchablePositions: ODSBottomSheetSize.allCases.map { $0.position },
switchablePositions: ODSBottomSheetSize.positions,
headerContent: {
BottomSheedHeader(title: title, subtitle: subtitle, icon: icon, applyRotation: false)
.onTapGesture {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,11 @@

import BottomSheet

extension ODSBottomSheetSize {
extension ODSBottomSheetSize: CaseIterable {
public static var allCases: [ODSBottomSheetSize] = [
.hidden, .small, .medium, .large,
]

var position: BottomSheetPosition {
switch self {
case .hidden:
Expand All @@ -22,7 +26,11 @@ extension ODSBottomSheetSize {
}
}

public init(from position: BottomSheetPosition) {
static var positions: [BottomSheetPosition] {
Self.allCases.map { $0.position }
}

init(from position: BottomSheetPosition) {
switch position {
case .hidden:
self = .hidden
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@

import SwiftUI

// swiftlint:disbale comment_spacing multiline_parameters_brackets vertical_parameter_alignment
public enum ODSBottomSheetSize: String, CaseIterable {
public enum ODSBottomSheetSize {
case hidden /// The state where the BottomSheet is hidden
case small /// The state where the BottomSheet is closed (`mainContent` is hidden)
case medium /// The state where the height of the BottomSheet is 50% of the screen
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ struct ODSButtonContent: View {
ODSIcon(image, size: 17)
}

text.odsFont(.bodyBold)
text.odsFont(.bodyLBold)
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ private struct ODSEmphasisButtonStyle: ButtonStyle {
backgroundColor: backgroundColor,
borderColor: borderColor,
fullWidth: fullWidth)
.odsFont(.bodyBold)
.odsFont(.bodyLBold)
}

// ======================
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ private struct ODSFunctionalButtonStyleV2: ButtonStyle {
backgroundColor: backgroundColor,
borderColor: borderColor,
fullWidth: fullWidth)
.odsFont(.bodyBold)
.odsFont(.bodyLBold)
}

// ======================
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,13 +65,13 @@ public struct ODSCardHorizontal: View {
/// Initialization with one button.
///
/// - Parameters:
/// - title: The title to be displayed in the card.
/// - imageSource: The image to be displayed in the card.
/// - imagePosition: The side where image is placed.
/// - subtitle: Optional subtitle to be displayed in the card.
/// - text: Optional text description to be displayed in the card. The text
/// - title: Title displayed into the card.
/// - imageSource: Image from source [ODSImage.Source] displayed into the card.
/// - imagePosition: Side where image is placed.
/// - subtitle: Optional subtitle displayed into the card.
/// - text: Optional text description displayed into the card. The text
/// displaying is limited to two lines (truncated tail).
/// - button: The optional first (leading) button.
/// - button: Optional first (leading) button.
/// - dividerEnabled: Optional divider added at the top of the buttons area.
///
public init(
Expand All @@ -97,14 +97,14 @@ public struct ODSCardHorizontal: View {
/// Initialization with two buttons.
///
/// - Parameters:
/// - title: The title to be displayed in the card.
/// - imageSource: The image to be displayed in the card.
/// - imagePosition: The side where image is placed.
/// - subtitle: Optional subtitle to be displayed in the card.
/// - text: Optional text description to be displayed in the card. The text
/// - title: Title displayed into the card.
/// - imageSource: Image from source [ODSImage.Source] displayed into the card.
/// - imagePosition: Side where image is placed.
/// - subtitle: Optional subtitle displayed into the card.
/// - text: Optional text description displayed into the card. The text
/// displaying is limited to two lines (truncated tail).
/// - firstButton: The optional first (leading) button.
/// - secondButton: The optional second (trailing) button.
/// - firstButton: Optional first (leading) button.
/// - secondButton: Optional second (trailing) button.
/// - dividerEnabled: Optional divider added at the top of the buttons area.
///
public init(
Expand Down Expand Up @@ -142,7 +142,7 @@ public struct ODSCardHorizontal: View {

VStack(alignment: .leading, spacing: ODSSpacing.xs) {
title
.odsFont(.bodyBold)
.odsFont(.bodyLBold)
.frame(maxWidth: .infinity, alignment: .leading)

subtitle?
Expand All @@ -152,6 +152,7 @@ public struct ODSCardHorizontal: View {
.lineLimit(2)
.frame(maxWidth: .infinity, alignment: .leading)
}
.accessibilityElement(children: .combine)
.foregroundColor(.primary)
.padding(.all, ODSSpacing.m)

Expand Down
Loading

0 comments on commit cda78da

Please sign in to comment.