SlideShare a Scribd company logo
1 of 55
Supporting
Arab* in your
web apps
‫ة‬َّ‫ي‬ِ‫ب‬َ‫ر‬َ‫ع‬‫ال‬
* And other languages
2
Now
2015
2010
2005
2000
Gil Faria
engineering lead
Let’s Begin
don’t forget the
disclaimers
who he is
Lead software
engineer with about a
decade of experience.
Works for a midsize
company
Meet Brian
who he thinks he is
Ninja. Samurai. Jedi.
Eats bits for breakfast,
CPU cycles for lunch
and threads for
dinner.
Basically the very best
software engineer in
the world!
4
who he is
Brian’s boss.
Manages the
department of
software
development.
Has an engineering
background but hasn’t
been in the field for
quite a while.
Meet John
who he thinks he is
The guy in control, a
born leader.
The Nelson Mandela in
the software industry.
5
“
Brian, we need to develop
a web site for our new
business idea:
6
“The Awesome Site that Sells
Everything”
TASSE
The team
proposal
team vision
We should use
Node, Ruby,
Python,
Angular,
React, PHP,
.NET
reality
We can’t
diversify
technologies
so Brian
breaks the
vibe by
imposing the
companies’
tech stack.
the app
Microsoft
ASP.NET MVC
for the
portuguese
market
7
this is huge
We should support
multiple languages.
We have to prepare
our application for
future expansion.
The Solution
but what is...
- Internationalization
- localization
- globalization
- localizability
- I18n
- i10n
- L12y
- G11N
8
Internationalization
“... design and development of a product,
application or document content that
enables easy localization for target
audiences that vary in culture, region, or
language.”
9
i18n
globalization
Localization
“... the adaptation of a product, application
or document content to meet the
language, cultural and other requirements
of a specific target market (a locale)...”
10
l10n
Demo
first web app
1
Big success
After a few sprints the team launched the app and it
went viral
12
Launching v1.0
“
Brian, we need to expand
our market reach
13
“TASSE needs to be in english,
Yesterday!”
But Brian was
prepared
The team had already prepared the
app (internationalization, right?)
14
And guess what? Brian and the team
know english!
“You are very white… put tha kream”
Now, they need to localize.
Big success
A short while after TASSE was localized for english
15
Launching v1.1
The board
decides to
expand the
business
16
TASSE
Expansion
English
Portugues
e
French
New Languages Needed
And Brian is ready...
Another localization project.
17
And guess what? Brian and the team
know french!
“Bonjour…. Merci… err”
Ok, they don’t know french, but
google knows!
Big sh!t
* number of tickets created with problems found with
translations (most were detected by clients)
18
*
Launching v1.2
Importance of Context
20
Try to translate this English word into another language
“Record”
Does Record refer to:
- the action of recording something?
- the product?
- the highest score in a game?
The problem
Brian decides to
create a new
database for TASSE,
which is responsible
for collecting and
delivering all
translation strings.
Looking for a Solution
Organization
Translation issues are
pushed out of the
engineering realm.
They can outsource
the translations.
Translators have
control of what to
translate in the right
context
21
After a few sprints
They created a new back office app, used internally, for the
translators.
From now on, all the translations where out of the
engineering scope.
22
Languages added
New languages were added
○ Italian
○ German
○ Spanish
Things were pretty normal
23
Big success
A short while after TASSE was localized in a few more
languages. Life is good.
24
Launching v1.x
“
Brian, we need to include
Arabic into TASSE
25
“It’s written from right to left!”
And Brian is ready
(of course)...
He thinks he knows all about RTL and
Arabic.
After all, the team had already
added a whole bunch of languages
to the site!!!
26
“Boss, I’ve already read about
this! The browser handles it all!”
Demo
RTL and the DOM
2
“
Let’s play it safe
28
John, this time, was cautious and
contracted a native speaking
consultant
Born and raised in Saudi Arabia.
The external consultant
29
Meet Amir
30 Modern Varieties
Ex: Some varieties from
Northern Africa are
incomprehensible to an
Arabic speaker in the Persian
gulf
Modern Standard Arabic
MSA - a formal language
Based on classic arabe
Learned at school 30
Arabic
31
Arabic Alphabet
It is written from right to left in a
cursive style and includes 28
letters. Most letters have more
than one shape.
Pluralization
32
English has two rules
1 day
2 days
1.5 days
Arabic has six rules
٠‫كتاب‬
‫ولد‬‫واحد‬‫حضر‬
‫ولدان‬‫حضرا‬
٣‫أوالد‬‫حضروا‬
١١‫ًا‬‫د‬‫ول‬‫حضروا‬
١٠٠‫ولد‬‫حضروا‬
0
1
2
n % 100 = 3..10
n % 100 = 11..99
100~102, 200~202, ...
33
What happens to images?
34
Are All images mirrored?
What about video?
35
Applying changes
Manually
explicitly write
rules for RTL and
LTR
CSS post-
processing (e.g.
with PostCSS.)
postcss-rtl
duplicates each
needed rule, with
selector for rtl/ltr
[dir=ltr] .foo
[dir=rtl] .foo
rtlcss
rewrites file
Less/Sass pre-processing
replace *-left/*-right
properties with functions
requires rewriting the
original files
if-ltr('left-to-right',
'right-to-left');
@include if-ltr {
p {
// some css...
}
}
36
Demo
RTLCSS
3
So is Arabic text RTL?
38
No
It’s actually bidi
Yes
bidirectional
Arabic is bidi
39
Translates to
The presence of the new USB 3.1 or USB Type-C in some phones this year was
a warning that this standard will be present on all telephones next year at
least high-end phones.
Unicode Bidirectional Algorithm
40
bidi algorithm
is part of the Unicode
Standard
widely supported by
web browsers and
other applications
base direction
we need to establish the
directional context of that text
dir attribute, or, in absence
inherited from the default
direction of the document,
which is left-to-right (LTR).
BIDI ALGORITHM BASICS
41
Directional runs
text is displayed
depends on the base
direction assigned
<p dir="ltr">bahrain ‫مصر‬kuwait</p>
<p dir="rtl">bahrain ‫مصر‬kuwait</p>
Characters may be
- strongly typed (letters)
- weak/neutral (numbers,
punctuation)
Let’s make this more exciting
42
spaces and punctuation are classed as neutral or weak characters
between two strongly typed characters with same directional type
assume that directionality
egypt, kuwait
LTR
<p dir="ltr">egypt, kuwait</p>
Neutral or weak characters
43
between two strongly typed characters with different directionality
same direction as the prevailing base direction.
egypt, ‫,البحرين‬ kuwait
LTR RTL LTR
<p dir="ltr">egypt, ‫,البحرين‬ kuwait</p>
LTRRTLLTR
Run direction changes
44
Hello World! is ! ‫مرحبا‬‫بالعالم‬ in Arabic
<p>Hello World! is <span dir="rtl"> ‫مفتاحمرحبا‬‫بالعالم‬ !</span>
in Arabic. </p>
<p>Hello World! is ‫مفتاحمرحبا‬‫بالعالم‬ ! in Arabic.</p>
at times it’s essential to change the direction run
What about numbers?
45
Weak characters don’t break
directional runs
Numbers are LTR even in RTL runs
Demo
Working with bidi
4
Editors with bidi support
47
Do Not
Atom
Visual Studio (PC + MAC)
Visual Studio Code (PC +
MAC)
Sublime text
Do
Emacs
Notepad++ (meh!)
Vim
Back to Brian
After a while, the team managed to add
another language.
48
Are they ready to launch another stable
version?
ARABIC
Big success
just a few minor issues...
49
Launching V.1.8
50
TASSE is a market
leader
Everyone’s happy!
<- SEE ->
51
And they all lived
happily ever after!
52
Always Use UTF-8 (or UTF-16 for asian languages) and nvarchar for the Database
Create localizable strings
● Don't assume grammar structures $“{singular} {plural}s”
● Don’t concatenate strings
● Date, time, units formats (don’t hard code structure) $“{day}{month}{year}”
● Don't reuse strings in different contexts
● Don't hardcode characters not even white spaces, commas, or other separators
Don’t forget
When translating, context is crucial
How About
a Test?
?
54
What’s wrong with this text?
there’s letter-spacing! it must be disabled
(thank you so much for coming)
Thank you!
Any Questions?
gil.faria@gmail.com
‫شكرا‬
56

More Related Content

Similar to Going Arabic - Tuga IT

Oh the compilers you'll build
Oh the compilers you'll buildOh the compilers you'll build
Oh the compilers you'll buildMark Stoodley
 
Go Global Fearless(I18N & L10N)
Go Global Fearless(I18N & L10N)Go Global Fearless(I18N & L10N)
Go Global Fearless(I18N & L10N)Venkat Rajesh
 
From Programming to Modeling And Back Again
From Programming to Modeling And Back AgainFrom Programming to Modeling And Back Again
From Programming to Modeling And Back AgainMarkus Voelter
 
whatiscodingslideshare-180406204414.pptx
whatiscodingslideshare-180406204414.pptxwhatiscodingslideshare-180406204414.pptx
whatiscodingslideshare-180406204414.pptxKanden ARMOOGUM
 
The REAL Angular Keynote
The REAL Angular KeynoteThe REAL Angular Keynote
The REAL Angular KeynoteLukas Ruebbelke
 
What is Coding
What is CodingWhat is Coding
What is CodingRoboGarden
 
Lecture 1 Compiler design , computation
Lecture 1 Compiler design , computation Lecture 1 Compiler design , computation
Lecture 1 Compiler design , computation Rebaz Najeeb
 
Laura Dent: Single-Source and Localization
Laura Dent: Single-Source and LocalizationLaura Dent: Single-Source and Localization
Laura Dent: Single-Source and LocalizationJack Molisani
 
COMPUTER LANGUAGES AND THERE DIFFERENCE
COMPUTER LANGUAGES AND THERE DIFFERENCE COMPUTER LANGUAGES AND THERE DIFFERENCE
COMPUTER LANGUAGES AND THERE DIFFERENCE Pavan Kalyan
 
DITA and Localization: Bringing the Best Together
DITA and Localization: Bringing the Best TogetherDITA and Localization: Bringing the Best Together
DITA and Localization: Bringing the Best TogetherLavaCon
 
How To be a Backend developer
How To be a Backend developer    How To be a Backend developer
How To be a Backend developer Ramy Hakam
 
The Ring programming language version 1.9 book - Part 6 of 210
The Ring programming language version 1.9 book - Part 6 of 210The Ring programming language version 1.9 book - Part 6 of 210
The Ring programming language version 1.9 book - Part 6 of 210Mahmoud Samir Fayed
 
Lect 1. introduction to programming languages
Lect 1. introduction to programming languagesLect 1. introduction to programming languages
Lect 1. introduction to programming languagesVarun Garg
 
The 10 Commandments of Building Global Software
The 10 Commandments of Building Global SoftwareThe 10 Commandments of Building Global Software
The 10 Commandments of Building Global SoftwareAndrey Akselrod
 
Programing fundamentals with C++
Programing fundamentals with C++Programing fundamentals with C++
Programing fundamentals with C++farooq2016
 
Domain Specific Languages
Domain Specific LanguagesDomain Specific Languages
Domain Specific Languageselliando dias
 

Similar to Going Arabic - Tuga IT (20)

Oh the compilers you'll build
Oh the compilers you'll buildOh the compilers you'll build
Oh the compilers you'll build
 
Python overview
Python overviewPython overview
Python overview
 
Go Global Fearless(I18N & L10N)
Go Global Fearless(I18N & L10N)Go Global Fearless(I18N & L10N)
Go Global Fearless(I18N & L10N)
 
From Programming to Modeling And Back Again
From Programming to Modeling And Back AgainFrom Programming to Modeling And Back Again
From Programming to Modeling And Back Again
 
whatiscodingslideshare-180406204414.pptx
whatiscodingslideshare-180406204414.pptxwhatiscodingslideshare-180406204414.pptx
whatiscodingslideshare-180406204414.pptx
 
The REAL Angular Keynote
The REAL Angular KeynoteThe REAL Angular Keynote
The REAL Angular Keynote
 
What is Coding
What is CodingWhat is Coding
What is Coding
 
Lecture 1 Compiler design , computation
Lecture 1 Compiler design , computation Lecture 1 Compiler design , computation
Lecture 1 Compiler design , computation
 
Laura Dent: Single-Source and Localization
Laura Dent: Single-Source and LocalizationLaura Dent: Single-Source and Localization
Laura Dent: Single-Source and Localization
 
Development tools
Development toolsDevelopment tools
Development tools
 
COMPUTER LANGUAGES AND THERE DIFFERENCE
COMPUTER LANGUAGES AND THERE DIFFERENCE COMPUTER LANGUAGES AND THERE DIFFERENCE
COMPUTER LANGUAGES AND THERE DIFFERENCE
 
DITA and Localization: Bringing the Best Together
DITA and Localization: Bringing the Best TogetherDITA and Localization: Bringing the Best Together
DITA and Localization: Bringing the Best Together
 
How To be a Backend developer
How To be a Backend developer    How To be a Backend developer
How To be a Backend developer
 
The Ring programming language version 1.9 book - Part 6 of 210
The Ring programming language version 1.9 book - Part 6 of 210The Ring programming language version 1.9 book - Part 6 of 210
The Ring programming language version 1.9 book - Part 6 of 210
 
Linux Sucks
Linux SucksLinux Sucks
Linux Sucks
 
Linux Sucks
Linux SucksLinux Sucks
Linux Sucks
 
Lect 1. introduction to programming languages
Lect 1. introduction to programming languagesLect 1. introduction to programming languages
Lect 1. introduction to programming languages
 
The 10 Commandments of Building Global Software
The 10 Commandments of Building Global SoftwareThe 10 Commandments of Building Global Software
The 10 Commandments of Building Global Software
 
Programing fundamentals with C++
Programing fundamentals with C++Programing fundamentals with C++
Programing fundamentals with C++
 
Domain Specific Languages
Domain Specific LanguagesDomain Specific Languages
Domain Specific Languages
 

Recently uploaded

Call Girls in Uttam Nagar Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Uttam Nagar Delhi 💯Call Us 🔝8264348440🔝Call Girls in Uttam Nagar Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Uttam Nagar Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
FULL ENJOY Call Girls In Mayur Vihar Delhi Contact Us 8377087607
FULL ENJOY Call Girls In Mayur Vihar Delhi Contact Us 8377087607FULL ENJOY Call Girls In Mayur Vihar Delhi Contact Us 8377087607
FULL ENJOY Call Girls In Mayur Vihar Delhi Contact Us 8377087607dollysharma2066
 
Russian Call Girls in Kolkata Ishita 🤌 8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls in Kolkata Ishita 🤌  8250192130 🚀 Vip Call Girls KolkataRussian Call Girls in Kolkata Ishita 🤌  8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls in Kolkata Ishita 🤌 8250192130 🚀 Vip Call Girls Kolkataanamikaraghav4
 
VIP 7001035870 Find & Meet Hyderabad Call Girls Dilsukhnagar high-profile Cal...
VIP 7001035870 Find & Meet Hyderabad Call Girls Dilsukhnagar high-profile Cal...VIP 7001035870 Find & Meet Hyderabad Call Girls Dilsukhnagar high-profile Cal...
VIP 7001035870 Find & Meet Hyderabad Call Girls Dilsukhnagar high-profile Cal...aditipandeya
 
VIP Kolkata Call Girl Kestopur 👉 8250192130 Available With Room
VIP Kolkata Call Girl Kestopur 👉 8250192130  Available With RoomVIP Kolkata Call Girl Kestopur 👉 8250192130  Available With Room
VIP Kolkata Call Girl Kestopur 👉 8250192130 Available With Roomdivyansh0kumar0
 
Chennai Call Girls Porur Phone 🍆 8250192130 👅 celebrity escorts service
Chennai Call Girls Porur Phone 🍆 8250192130 👅 celebrity escorts serviceChennai Call Girls Porur Phone 🍆 8250192130 👅 celebrity escorts service
Chennai Call Girls Porur Phone 🍆 8250192130 👅 celebrity escorts servicesonalikaur4
 
Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)
Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)
Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)Dana Luther
 
定制(Lincoln毕业证书)新西兰林肯大学毕业证成绩单原版一比一
定制(Lincoln毕业证书)新西兰林肯大学毕业证成绩单原版一比一定制(Lincoln毕业证书)新西兰林肯大学毕业证成绩单原版一比一
定制(Lincoln毕业证书)新西兰林肯大学毕业证成绩单原版一比一Fs
 
Low Rate Call Girls Kolkata Avani 🤌 8250192130 🚀 Vip Call Girls Kolkata
Low Rate Call Girls Kolkata Avani 🤌  8250192130 🚀 Vip Call Girls KolkataLow Rate Call Girls Kolkata Avani 🤌  8250192130 🚀 Vip Call Girls Kolkata
Low Rate Call Girls Kolkata Avani 🤌 8250192130 🚀 Vip Call Girls Kolkataanamikaraghav4
 
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girlsstephieert
 
Git and Github workshop GDSC MLRITM
Git and Github  workshop GDSC MLRITMGit and Github  workshop GDSC MLRITM
Git and Github workshop GDSC MLRITMgdsc13
 
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一Fs
 
How is AI changing journalism? (v. April 2024)
How is AI changing journalism? (v. April 2024)How is AI changing journalism? (v. April 2024)
How is AI changing journalism? (v. April 2024)Damian Radcliffe
 
VIP Kolkata Call Girl Alambazar 👉 8250192130 Available With Room
VIP Kolkata Call Girl Alambazar 👉 8250192130  Available With RoomVIP Kolkata Call Girl Alambazar 👉 8250192130  Available With Room
VIP Kolkata Call Girl Alambazar 👉 8250192130 Available With Roomdivyansh0kumar0
 
Call Girls Service Adil Nagar 7001305949 Need escorts Service Pooja Vip
Call Girls Service Adil Nagar 7001305949 Need escorts Service Pooja VipCall Girls Service Adil Nagar 7001305949 Need escorts Service Pooja Vip
Call Girls Service Adil Nagar 7001305949 Need escorts Service Pooja VipCall Girls Lucknow
 
Russian Call Girls in Kolkata Samaira 🤌 8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls in Kolkata Samaira 🤌  8250192130 🚀 Vip Call Girls KolkataRussian Call Girls in Kolkata Samaira 🤌  8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls in Kolkata Samaira 🤌 8250192130 🚀 Vip Call Girls Kolkataanamikaraghav4
 
Denver Web Design brochure for public viewing
Denver Web Design brochure for public viewingDenver Web Design brochure for public viewing
Denver Web Design brochure for public viewingbigorange77
 

Recently uploaded (20)

Call Girls in Uttam Nagar Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Uttam Nagar Delhi 💯Call Us 🔝8264348440🔝Call Girls in Uttam Nagar Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Uttam Nagar Delhi 💯Call Us 🔝8264348440🔝
 
Hot Sexy call girls in Rk Puram 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in  Rk Puram 🔝 9953056974 🔝 Delhi escort ServiceHot Sexy call girls in  Rk Puram 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Rk Puram 🔝 9953056974 🔝 Delhi escort Service
 
FULL ENJOY Call Girls In Mayur Vihar Delhi Contact Us 8377087607
FULL ENJOY Call Girls In Mayur Vihar Delhi Contact Us 8377087607FULL ENJOY Call Girls In Mayur Vihar Delhi Contact Us 8377087607
FULL ENJOY Call Girls In Mayur Vihar Delhi Contact Us 8377087607
 
Russian Call Girls in Kolkata Ishita 🤌 8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls in Kolkata Ishita 🤌  8250192130 🚀 Vip Call Girls KolkataRussian Call Girls in Kolkata Ishita 🤌  8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls in Kolkata Ishita 🤌 8250192130 🚀 Vip Call Girls Kolkata
 
VIP 7001035870 Find & Meet Hyderabad Call Girls Dilsukhnagar high-profile Cal...
VIP 7001035870 Find & Meet Hyderabad Call Girls Dilsukhnagar high-profile Cal...VIP 7001035870 Find & Meet Hyderabad Call Girls Dilsukhnagar high-profile Cal...
VIP 7001035870 Find & Meet Hyderabad Call Girls Dilsukhnagar high-profile Cal...
 
Call Girls In South Ex 📱 9999965857 🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SERVICE
Call Girls In South Ex 📱  9999965857  🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SERVICECall Girls In South Ex 📱  9999965857  🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SERVICE
Call Girls In South Ex 📱 9999965857 🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SERVICE
 
VIP Kolkata Call Girl Kestopur 👉 8250192130 Available With Room
VIP Kolkata Call Girl Kestopur 👉 8250192130  Available With RoomVIP Kolkata Call Girl Kestopur 👉 8250192130  Available With Room
VIP Kolkata Call Girl Kestopur 👉 8250192130 Available With Room
 
Chennai Call Girls Porur Phone 🍆 8250192130 👅 celebrity escorts service
Chennai Call Girls Porur Phone 🍆 8250192130 👅 celebrity escorts serviceChennai Call Girls Porur Phone 🍆 8250192130 👅 celebrity escorts service
Chennai Call Girls Porur Phone 🍆 8250192130 👅 celebrity escorts service
 
Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)
Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)
Packaging the Monolith - PHP Tek 2024 (Breaking it down one bite at a time)
 
定制(Lincoln毕业证书)新西兰林肯大学毕业证成绩单原版一比一
定制(Lincoln毕业证书)新西兰林肯大学毕业证成绩单原版一比一定制(Lincoln毕业证书)新西兰林肯大学毕业证成绩单原版一比一
定制(Lincoln毕业证书)新西兰林肯大学毕业证成绩单原版一比一
 
Low Rate Call Girls Kolkata Avani 🤌 8250192130 🚀 Vip Call Girls Kolkata
Low Rate Call Girls Kolkata Avani 🤌  8250192130 🚀 Vip Call Girls KolkataLow Rate Call Girls Kolkata Avani 🤌  8250192130 🚀 Vip Call Girls Kolkata
Low Rate Call Girls Kolkata Avani 🤌 8250192130 🚀 Vip Call Girls Kolkata
 
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls
10.pdfMature Call girls in Dubai +971563133746 Dubai Call girls
 
Git and Github workshop GDSC MLRITM
Git and Github  workshop GDSC MLRITMGit and Github  workshop GDSC MLRITM
Git and Github workshop GDSC MLRITM
 
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一
定制(AUT毕业证书)新西兰奥克兰理工大学毕业证成绩单原版一比一
 
How is AI changing journalism? (v. April 2024)
How is AI changing journalism? (v. April 2024)How is AI changing journalism? (v. April 2024)
How is AI changing journalism? (v. April 2024)
 
VIP Kolkata Call Girl Alambazar 👉 8250192130 Available With Room
VIP Kolkata Call Girl Alambazar 👉 8250192130  Available With RoomVIP Kolkata Call Girl Alambazar 👉 8250192130  Available With Room
VIP Kolkata Call Girl Alambazar 👉 8250192130 Available With Room
 
Call Girls Service Adil Nagar 7001305949 Need escorts Service Pooja Vip
Call Girls Service Adil Nagar 7001305949 Need escorts Service Pooja VipCall Girls Service Adil Nagar 7001305949 Need escorts Service Pooja Vip
Call Girls Service Adil Nagar 7001305949 Need escorts Service Pooja Vip
 
Russian Call Girls in Kolkata Samaira 🤌 8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls in Kolkata Samaira 🤌  8250192130 🚀 Vip Call Girls KolkataRussian Call Girls in Kolkata Samaira 🤌  8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls in Kolkata Samaira 🤌 8250192130 🚀 Vip Call Girls Kolkata
 
young call girls in Uttam Nagar🔝 9953056974 🔝 Delhi escort Service
young call girls in Uttam Nagar🔝 9953056974 🔝 Delhi escort Serviceyoung call girls in Uttam Nagar🔝 9953056974 🔝 Delhi escort Service
young call girls in Uttam Nagar🔝 9953056974 🔝 Delhi escort Service
 
Denver Web Design brochure for public viewing
Denver Web Design brochure for public viewingDenver Web Design brochure for public viewing
Denver Web Design brochure for public viewing
 

Going Arabic - Tuga IT

  • 1. Supporting Arab* in your web apps ‫ة‬َّ‫ي‬ِ‫ب‬َ‫ر‬َ‫ع‬‫ال‬ * And other languages
  • 4. who he is Lead software engineer with about a decade of experience. Works for a midsize company Meet Brian who he thinks he is Ninja. Samurai. Jedi. Eats bits for breakfast, CPU cycles for lunch and threads for dinner. Basically the very best software engineer in the world! 4
  • 5. who he is Brian’s boss. Manages the department of software development. Has an engineering background but hasn’t been in the field for quite a while. Meet John who he thinks he is The guy in control, a born leader. The Nelson Mandela in the software industry. 5
  • 6. “ Brian, we need to develop a web site for our new business idea: 6 “The Awesome Site that Sells Everything” TASSE
  • 7. The team proposal team vision We should use Node, Ruby, Python, Angular, React, PHP, .NET reality We can’t diversify technologies so Brian breaks the vibe by imposing the companies’ tech stack. the app Microsoft ASP.NET MVC for the portuguese market 7
  • 8. this is huge We should support multiple languages. We have to prepare our application for future expansion. The Solution but what is... - Internationalization - localization - globalization - localizability - I18n - i10n - L12y - G11N 8
  • 9. Internationalization “... design and development of a product, application or document content that enables easy localization for target audiences that vary in culture, region, or language.” 9 i18n globalization
  • 10. Localization “... the adaptation of a product, application or document content to meet the language, cultural and other requirements of a specific target market (a locale)...” 10 l10n
  • 12. Big success After a few sprints the team launched the app and it went viral 12 Launching v1.0
  • 13. “ Brian, we need to expand our market reach 13 “TASSE needs to be in english, Yesterday!”
  • 14. But Brian was prepared The team had already prepared the app (internationalization, right?) 14 And guess what? Brian and the team know english! “You are very white… put tha kream” Now, they need to localize.
  • 15. Big success A short while after TASSE was localized for english 15 Launching v1.1
  • 16. The board decides to expand the business 16 TASSE Expansion English Portugues e French New Languages Needed
  • 17. And Brian is ready... Another localization project. 17 And guess what? Brian and the team know french! “Bonjour…. Merci… err” Ok, they don’t know french, but google knows!
  • 18. Big sh!t * number of tickets created with problems found with translations (most were detected by clients) 18 * Launching v1.2
  • 19. Importance of Context 20 Try to translate this English word into another language “Record” Does Record refer to: - the action of recording something? - the product? - the highest score in a game?
  • 20. The problem Brian decides to create a new database for TASSE, which is responsible for collecting and delivering all translation strings. Looking for a Solution Organization Translation issues are pushed out of the engineering realm. They can outsource the translations. Translators have control of what to translate in the right context 21
  • 21. After a few sprints They created a new back office app, used internally, for the translators. From now on, all the translations where out of the engineering scope. 22
  • 22. Languages added New languages were added ○ Italian ○ German ○ Spanish Things were pretty normal 23
  • 23. Big success A short while after TASSE was localized in a few more languages. Life is good. 24 Launching v1.x
  • 24. “ Brian, we need to include Arabic into TASSE 25 “It’s written from right to left!”
  • 25. And Brian is ready (of course)... He thinks he knows all about RTL and Arabic. After all, the team had already added a whole bunch of languages to the site!!! 26 “Boss, I’ve already read about this! The browser handles it all!”
  • 27. “ Let’s play it safe 28 John, this time, was cautious and contracted a native speaking consultant
  • 28. Born and raised in Saudi Arabia. The external consultant 29 Meet Amir
  • 29. 30 Modern Varieties Ex: Some varieties from Northern Africa are incomprehensible to an Arabic speaker in the Persian gulf Modern Standard Arabic MSA - a formal language Based on classic arabe Learned at school 30 Arabic
  • 30. 31 Arabic Alphabet It is written from right to left in a cursive style and includes 28 letters. Most letters have more than one shape.
  • 31. Pluralization 32 English has two rules 1 day 2 days 1.5 days Arabic has six rules ٠‫كتاب‬ ‫ولد‬‫واحد‬‫حضر‬ ‫ولدان‬‫حضرا‬ ٣‫أوالد‬‫حضروا‬ ١١‫ًا‬‫د‬‫ول‬‫حضروا‬ ١٠٠‫ولد‬‫حضروا‬ 0 1 2 n % 100 = 3..10 n % 100 = 11..99 100~102, 200~202, ...
  • 33. 34 Are All images mirrored?
  • 35. Applying changes Manually explicitly write rules for RTL and LTR CSS post- processing (e.g. with PostCSS.) postcss-rtl duplicates each needed rule, with selector for rtl/ltr [dir=ltr] .foo [dir=rtl] .foo rtlcss rewrites file Less/Sass pre-processing replace *-left/*-right properties with functions requires rewriting the original files if-ltr('left-to-right', 'right-to-left'); @include if-ltr { p { // some css... } } 36
  • 37. So is Arabic text RTL? 38 No It’s actually bidi Yes bidirectional
  • 38. Arabic is bidi 39 Translates to The presence of the new USB 3.1 or USB Type-C in some phones this year was a warning that this standard will be present on all telephones next year at least high-end phones.
  • 39. Unicode Bidirectional Algorithm 40 bidi algorithm is part of the Unicode Standard widely supported by web browsers and other applications base direction we need to establish the directional context of that text dir attribute, or, in absence inherited from the default direction of the document, which is left-to-right (LTR).
  • 40. BIDI ALGORITHM BASICS 41 Directional runs text is displayed depends on the base direction assigned <p dir="ltr">bahrain ‫مصر‬kuwait</p> <p dir="rtl">bahrain ‫مصر‬kuwait</p> Characters may be - strongly typed (letters) - weak/neutral (numbers, punctuation)
  • 41. Let’s make this more exciting 42 spaces and punctuation are classed as neutral or weak characters between two strongly typed characters with same directional type assume that directionality egypt, kuwait LTR <p dir="ltr">egypt, kuwait</p>
  • 42. Neutral or weak characters 43 between two strongly typed characters with different directionality same direction as the prevailing base direction. egypt, ‫,البحرين‬ kuwait LTR RTL LTR <p dir="ltr">egypt, ‫,البحرين‬ kuwait</p>
  • 43. LTRRTLLTR Run direction changes 44 Hello World! is ! ‫مرحبا‬‫بالعالم‬ in Arabic <p>Hello World! is <span dir="rtl"> ‫مفتاحمرحبا‬‫بالعالم‬ !</span> in Arabic. </p> <p>Hello World! is ‫مفتاحمرحبا‬‫بالعالم‬ ! in Arabic.</p> at times it’s essential to change the direction run
  • 44. What about numbers? 45 Weak characters don’t break directional runs Numbers are LTR even in RTL runs
  • 46. Editors with bidi support 47 Do Not Atom Visual Studio (PC + MAC) Visual Studio Code (PC + MAC) Sublime text Do Emacs Notepad++ (meh!) Vim
  • 47. Back to Brian After a while, the team managed to add another language. 48 Are they ready to launch another stable version? ARABIC
  • 48. Big success just a few minor issues... 49 Launching V.1.8
  • 49. 50 TASSE is a market leader Everyone’s happy! <- SEE ->
  • 50. 51 And they all lived happily ever after!
  • 51. 52 Always Use UTF-8 (or UTF-16 for asian languages) and nvarchar for the Database Create localizable strings ● Don't assume grammar structures $“{singular} {plural}s” ● Don’t concatenate strings ● Date, time, units formats (don’t hard code structure) $“{day}{month}{year}” ● Don't reuse strings in different contexts ● Don't hardcode characters not even white spaces, commas, or other separators Don’t forget When translating, context is crucial
  • 53. 54 What’s wrong with this text? there’s letter-spacing! it must be disabled (thank you so much for coming)
  • 55. 56

Editor's Notes

  1. Globalization (G11N): The process of making an app support different languages and regions. Localization (L10N): The process of customizing an app for a given language and region.
  2. Internationalization significantly affects the ease of the product's localization. Retrofitting a linguistically- and culturally-centered deliverable for a global market is obviously much more difficult and time-consuming than designing a deliverable with the intent of presenting it globally.
  3. Localizability - L12y Localization (L10N): The process of customizing an app for a given language and region.
  4. excellent, formidable, find very funny. Uma coisa muito engraçada https://translate.google.pt/#fr/en/Se%20taper%20le%20cul%20par%20terre https://dictionnaire.reverso.net/francais-definition/%C3%A0+se+taper+le+cul+par+terre
  5. https://www.google.pt/search?q=localization+issues+in+vairuos+lanugafges&oq=localization+issues+in+vairuos+lanugages&aqs=chrome..69i57.10373j0j7&sourceid=chrome&ie=UTF-8
  6. Show that images and glyphs don’t change! We need more than the dir attrib
  7. http://www.unicode.org/cldr/charts/29/supplemental/language_plural_rules.html
  8. https://material.io/guidelines/usability/bidirectionality.html
  9. https://www.youtube.com/watch?v=TigrPM1FLpA
  10. https://www.w3.org/International/articles/inline-bidi-markup/uba-basics
  11. Bahrein, Egito, Kuwait
  12. baraheim
  13. Hello {0}, welcome back! مرحبًا {0}، مرحبًا بك مرة أخرى!
  14. https://en.wikipedia.org/wiki/Comparison_of_text_editors
  15. https://www.google.pt/search?q=localization+issues+in+vairuos+lanugafges&oq=localization+issues+in+vairuos+lanugages&aqs=chrome..69i57.10373j0j7&sourceid=chrome&ie=UTF-8
  16. UTF-8 can accurately represent the entire Unicode range of characters, but it is optimized for text that is mostly ASCII. UTF-16 is space-efficient over the entire Basic Multilingual Plane
  17. Thank you netponto, hope you enjoyed the event
  18. shukraan lakum!