-
Notifications
You must be signed in to change notification settings - Fork 1
0 ‐ FAQ (Frequently Asked Questions)
OUDS means "Orange Unified Design System". This is a new design system, again, but unified, trying to merge all requirements of Orange brands and affiliates so as to provide a unique design system, unified across all platforms and for all countries, companies, users and apps. Guidelines for TV, Android, iOS and web environments will be merged in a "cohesive" approach, and any Orange-related softwares including brand apps like Parnasse and Sosh, Orange Innovation Cup apps and Orange countries and affiliates apps will have to use this project in the future. The project is open source and topics like accessibility and ecodesign are also managed. Some assets related to brand, like for Sosh or Parnasse are not planned ot be released in open source mode and will be defined in internal repositories.
Today OUDS provides an Android library, this iOS library and a web library. A Flutter version is in progress also.
The Orange theme is provided, as the default theme. There is also an inverse theme for particular use cases. Brands themes like Sosh are not managed yet, but are planned to be, and will be defined in our internal repository so as to not allow users to subclass it and use it except if allowed.
No components have been implemented yet, but we hope to have some of them at for the end of the year (buttons, text inputs).
All specifications are defined in Figma, used by the design team, even if we struggle to have well defined issues on GitHub for transparency and comfort of use. Do not expect to have much details here, sadly. You can find plenty of details in the official website at unified-design-system.orange.com.
To allow Orange subcontractors and affiliates, and also countries instances in fact, to use the OUDS products, it was necessary to provide the source code under an open source licence to avoid recharging or billing troubles within distinct juridical entities. MIT was enough permissive and understandable, so has been used. For legal reasons, it was not possible to keep internally the source code and give it to affiliates and subcontractors for free. For the same reasons, no inner source license was applied, nor common source process.
ODS means "Orange Design System". It was an attempt to define whole new design system but for Orange affiliates and countries in AMEA and Europe areas. It provides components and themes for Android, iOS and Flutter apps and web projects. But because this design system did not embed the One-I system of Orange France, the project has been delayed, almost considered as unmaintained with two years of work and efforts wasted.
tokenator is a name given to an internal project based on amzn/style-dictionary (under Apache 2.0 license), with a lot of customizations, which will convert JSON files generated by Figma to Kotlin, Swift and Web objects for the own needs of the OUDS librairies ; that is the reason why there is no interest in publishing it in open source, it remains internal. The tool provides modifications using pull requests and a dedicated GitHub account. You can find tokenator contributions by filtering the Git history.
With version 0.8.0, we will provide 1,400 tokens:
- 429 core raw tokens
- 22 Orange brand raw tokens
- 976 core semantic tokens
Yo can find below a Python script to compute the number of tokens. In few words, here are the outputs:
Core raw tokens:
ElevationRawTokens+Values.swift: 16
FontRawTokens+Values.swift: 61
ColorRawTokens+Values.swift: 170
OpacityRawTokens+Values.swift: 25
FontRawTokens+Composites.swift: 21
DimensionRawTokens+Values.swift: 36
GridRawTokens+Values.swift: 30
ElevationRawTokens+Composites.swift: 37
BorderRawTokens+Values.swift: 25
Core raw tokens --> 421
Orange raw tokens:
OrangeBrandColorRawTokens+Values.swift: 20
OrangeBrandFontRawTokens+Values.swift: 2
Orange raw tokens --> 22
Core semantic tokens:
GridSemanticTokens.swift: 12
BorderSemanticTokens.swift: 15
SpaceMultipleSemanticTokens.swift: 13
SizeSemanticTokens.swift: 83
ElevationCompositeSemanticTokens.swift: 11
OpacitySemanticTokens.swift: 6
ColorMultipleSemanticTokens.swift: 174
ColorSemanticTokens.swift: 342
FontMultipleSemanticTokens.swift: 33
FontCompositeSemanticTokens.swift: 24
ElevationSemanticTokens.swift: 34
SpaceSemanticTokens.swift: 80
SizeMultipleSemanticTokens.swift: 34
FontSemanticTokens.swift: 85
ElevationMultipleSemanticTokens.swift: 11
Core semantic tokens --> 957
Total number of tokens --> 1400
And the Python code:
#!/usr/bin/env python3
# SPDX-FileCopyrightText: Copyright (c) Orange SA
# SPDX-License-Identifier: MIT
import os
def count_pattern_in_file(file_path, pattern):
"""
Counts the number of instances for each pattern in a file.
Args:
file_path (str): Path to the file to process.
pattern (str): Pattern to look for.
Returns:
int: Number of instances of the pattern in the file.
"""
try:
with open(file_path, 'r', encoding='utf-8') as file:
content = file.read()
return content.count(pattern)
except Exception as e:
print(f"Error: Error while reading the file '{file_path}': '{e}'")
return 0
def count_patterns_in_directory(directory, pattern):
"""
Counts the number of instances of pattern in all files of given directory.
Args:
directory (str): Path of directory to process.
pattern (str): The apttern to look for.
Returns:
dict: Dictionnary with paths of files as keys and instances numbers as values.
"""
results = {}
if os.path.isdir(directory):
for root, _, files in os.walk(directory):
for file in files:
file_path = os.path.join(root, file)
count = count_pattern_in_file(file_path, pattern)
results[file] = count
else:
print(f"Error: The directory '{directory}' does not exist")
return results
# ------------ Main ------------
if __name__ == "__main__":
# Update references to directories of course
# Do not forget to `chmod u+x` the file
# And define the path to the ouds-ios repository
project_root = "ouds-ios/OUDS/Core/"
global_accumulator = 0
print("Core raw tokens:")
occurrences = count_patterns_in_directory(project_root + "Tokens/RawTokens/Sources/Values", "public static let")
accumulator = 0
for file, counts in occurrences.items():
print(f"\t {file}: {counts}")
accumulator += counts
print(f"Core raw tokens --> {accumulator}")
global_accumulator += accumulator
print("\nOrange raw tokens:")
occurrences = count_patterns_in_directory(project_root + "Themes/Orange/Sources/Values", "public static let")
accumulator = 0
for file, counts in occurrences.items():
print(f"\t {file}: {counts}")
accumulator += counts
print(f"Orange raw tokens --> {accumulator}")
global_accumulator += accumulator
print("\nCore semantic tokens:")
occurrences = count_patterns_in_directory(project_root + "Tokens/SemanticTokens/Sources/Values", "var")
accumulator = 0
for file, counts in occurrences.items():
print(f"\t{file}: {counts}")
accumulator += counts
print(f"Core semantic tokens --> {accumulator}")
global_accumulator += accumulator
print(f"\nTotal number of tokens --> {global_accumulator}")