Skip to content

Commit

Permalink
Merge pull request #56 from OpenPecha/feat/localization-bo-hard-code
Browse files Browse the repository at this point in the history
Feat/localization bo hard code
  • Loading branch information
Lungsangg authored Feb 15, 2024
2 parents 7d7f16a + d09b50e commit 89b0c87
Show file tree
Hide file tree
Showing 9 changed files with 462 additions and 654 deletions.
614 changes: 211 additions & 403 deletions README.mkd

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions sefaria/model/tests/portal_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -438,12 +438,12 @@
"about": {
"title": {
"en": "About Us",
"he": "עלינו"
"he": "ང་ཚོའི་སྐོར།"
},
"image_uri": 67890,
"description": {
"en": "Description in English",
"he": "תיאור בעברית"
"he": "བོད་ཡིག་ནང་འགྲེལ་བ།"
}
}
},
Expand All @@ -454,18 +454,18 @@
"about": {
"title": {
"en": "About Us",
"he": "עלינו"
"he": "ང་ཚོའི་སྐོར།"
},
"image_uri": "gs://bucket/image.jpg",
"description": {
"en": "Description in English",
"he": "תיאור בעברית"
"he": " བོད་ཡིག་ནང་འགྲེལ་བ།"
}
},
"mobile": {
"title": {
"en": "Mobile App",
"he": "אפליקציה ניידת"
"he": "ཁ་པར་མཉེན་ཆས།"
},
"android_link": "https://play.google.com/store/apps/details?id=com.example.app",
"ios_link": "https://apps.apple.com/us/app/example-app/id1234567890",
Expand Down
52 changes: 26 additions & 26 deletions static/js/Footer.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,43 +41,43 @@ class Footer extends Component {
return (
<footer id="footer" className="static sans-serif">
<div id="footerInner">
<Section en="About" he="אודות">
<Link href="/about" en="What is Pecha?" he="מהי ספריא" />
<Link href="/help" en="Help" he="עזרה" />
<Link href="/team" en="Team" he="צוות" />
<Section en="About" he="དྲ་ཚིགས་ཀྱི་སྐོར།">
<Link href="/about" en="What is Pecha?" he="དཔེ་ཆ་དྲ་ཚིགས་ཅི་ཞིག་ཡིན་ནམ།" />
<Link href="/help" en="Help" he="རམ་འདེགས།" />
<Link href="/team" en="Team" he="ཚོགས་ཆུང་།" />
{/*<Link href="/testimonials" en="Testimonials" he="חוות דעת" />
<Link href="/metrics" en="Metrics" he="מדדים" />
<Link href="/annualreport/2022" en="Annual Report" he='דו"ח שנתי' />*/}
<Link href="/terms" en="Terms of Use" he="תנאי שימוש" />
<Link href="/privacy-policy" en="Privacy Policy" he="מדיניות פרטיות" />
<Link href="/terms" en="Terms of Use" he="བཀོལ་སྤྱོད་སྒྲིག་གཞི། " />
<Link href="/privacy-policy" en="Privacy Policy" he="སྒེར་དོན་གསང་རྒྱ། " />
</Section>

<Section en="Tools" he="כלים">
<Section en="Tools" he="ལག་ཆ་རྣམས།">
{/*<Link href="/educators" en="Teach with Sefaria" he="מלמדים עם ספריא" />
<Link href="/calendars" en="Learning Schedules" he="לוח לימוד יומי" />*/}
<Link href="/sheets" en="Source Sheets" he="דפי מקורות" />
<Link href="/sheets" en="Source Sheets" he="མ་ཕྱིའི་ཤོག་ངོས། " />
{/*<Link href="/visualizations" en="Visualizations" he="תרשימים גרפיים" />*/}
<Link href="/mobile" en="Mobile Apps" he="ספריא בנייד" />
<Link href="/mobile" en="Mobile Apps" he="ཁ་པར་མཉེན་ཆས།" />
{/*<Link href="/daf-yomi" en="Daf Yomi" he="דף יומי" />
<Link href="/torah-tab" en="Torah Tab" he="תורה טאב" />*/}
<Link href="/people" en="Authors" he="מחברים" />
<Link href="/collections" en="Collections" he="אסופות" />
<Link href="/updates" en="New Additions" he="עדכונים" />
<Link href="/people" en="Authors" he="རྩོམ་པ་པོའི་སྡེ།" />
<Link href="/collections" en="Collections" he="ཕྱོགས་བསྒྲིགས་ཁག" />
<Link href="/updates" en="New Additions" he="དཔར་གཞི་གསར་པ།" />
{/*<Link href="/remote-learning" en="Remote Learning" he="למידה מרחוק" />*/}
</Section>

<Section en="Developers" he="מפתחים">
<Link href="/developers" en="Get Involved" he="הצטרפו אלינו" blank={true} />
<Link href="/developers#api" en="API Docs" he="מסמכי API" blank={true} />
<Section en="Developers" he="ལས་བཟོ་བའི་སྡེ།">
<Link href="/developers" en="Get Involved" he=" མཉམ་ཞུགས་བྱོས།" blank={true} />
<Link href="/developers#api" en="API Docs" he="API Docs" blank={true} />
<Link href="https://github.com/Sefaria/Sefaria-Project" en="Fork us on GitHub" he="Github" blank={true} />
<Link href="https://github.com/Sefaria/Sefaria-Export" en="Download our Data" he="בסיס נתונים" blank={true} />
<Link href="https://github.com/Sefaria/Sefaria-Export" en="Download our Data" he="ང་ཚོའི་གཞི་གྲངས་ཕབ་ལེན།" blank={true} />
</Section>

<Section en="Join Us" he="הצטרפו אלינו">
<Section en="Join Us" he="ང་ཚོར་མཉམ་ཞུགས།">
{/*<DonateLink source={"Footer"}><InterfaceText text={{en:"Donate", he:"תרומות"}}/></DonateLink>
<Link href="/ways-to-give" en="Ways to Give" he="אפשרויות תרומה" />*/}
<Link href="/supporters" en="Supporters" he="תומכים" />
<Link href="/jobs" en="Jobs" he="דרושים" />
<Link href="/supporters" en="Supporters" he="རྒྱབ་སྐྱོར་བྱེད་མཁན།" />
<Link href="/jobs" en="Jobs" he="ལས་རིགས།" />
{/*<Link href="https://store.sefaria.org" en="Shop" he="חנות" />*/}
</Section>

Expand All @@ -88,19 +88,19 @@ class Footer extends Component {
{/*<NewsletterSignUpForm contextName="Footer" />*/}
<LikeFollowButtons />
<div className="socialLinks">
<Link href={fbURL} en="Facebook" he="פייסבוק" blank={true}/>
<Link href={fbURL} en="Facebook" he="ངོ་དེབ།" blank={true}/>
&bull;
<Link href="https://twitter.com/SefariaProject" en="Twitter" he="טוויטר" />
<Link href="https://twitter.com/SefariaProject" en="Twitter" he="ཁྲི་བའི་ཕྲར།" />
<br />

<Link href="https://www.youtube.com/user/SefariaProject" en="YouTube" he="יוטיוב" />
<Link href="https://www.youtube.com/user/SefariaProject" en="YouTube" he="ཡུས་ཁྲུབ།" />
&bull;
<Link href={blgURL} en="Blog" he="בלוג" blank={true}/>
<Link href={blgURL} en="Blog" he="Blog" blank={true}/>
<br />

<Link href="https://www.instagram.com/sefariaproject/" en="Instagram" he="אינסטגרם" />
<Link href="https://www.instagram.com/sefariaproject/" en="Instagram" he="Instagram" />
&bull;
<Link href="mailto:[email protected]" en="Email" he="דוא&quot;ל" />
<Link href="mailto:[email protected]" en="Email" he="གློག་འཕྲིན།" />
</div>
<div id="siteLanguageToggle">
<div id="siteLanguageToggleLabel">
Expand All @@ -111,7 +111,7 @@ class Footer extends Component {
</a>
|
<a href={"/interface/hebrew?next=" + next} id="siteLanguageHebrew"
onClick={this.trackLanguageClick.bind(null, "Hebrew")}>עברית
onClick={this.trackLanguageClick.bind(null, "Hebrew")}>བོད་ཡིག
</a>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions static/js/Header.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -610,7 +610,7 @@ const ProfilePicMenu = ({len, url, name}) => {
<InterfaceText>Account Settings</InterfaceText>
</a></div>
<div className="interfaceLinks-row languages">
<a className={`${(Sefaria.interfaceLang == 'hebrew') ? 'active':''}`} href={`/interface/hebrew?next=${getCurrentPage()}`} id="select-hebrew-interface-link">עברית</a>
<a className={`${(Sefaria.interfaceLang == 'hebrew') ? 'active':''}`} href={`/interface/hebrew?next=${getCurrentPage()}`} id="select-hebrew-interface-link">བོད་ཡིག</a>
<a className={`${(Sefaria.interfaceLang == 'english') ? 'active':''}`} href={`/interface/english?next=${getCurrentPage()}`} id="select-english-interface-link">English</a>
</div>
<div><a className="interfaceLinks-row bottom" id="help-link" href="/help">
Expand All @@ -633,15 +633,15 @@ const MobileInterfaceLanguageToggle = () => {

const links = Sefaria.interfaceLang == "hebrew" ?
<>
<a href={"/interface/hebrew?next=" + currentURL} className="int-he">עברית</a>
<a href={"/interface/hebrew?next=" + currentURL} className="int-he">བོད་ཡིག</a>
<span className="separator"></span>
<a href={"/interface/english?next=" + currentURL} className="int-en inactive">English</a>
</>
:
<>
<a href={"/interface/english?next=" + currentURL} className="int-en">English</a>
<span className="separator"></span>
<a href={"/interface/hebrew?next=" + currentURL} className="int-he inactive">עברית</a>
<a href={"/interface/hebrew?next=" + currentURL} className="int-he inactive">བོད་ཡིག</a>
</>;

return (
Expand Down
2 changes: 1 addition & 1 deletion static/js/Misc.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -1421,7 +1421,7 @@ function InterfaceLanguageMenu({currentLang, translationLanguagePreference, setT
<InterfaceText>Site Language</InterfaceText>
</div>
<div className="interfaceLinks-options">
<a className={`interfaceLinks-option int-bi int-he ${(currentLang == 'hebrew') ? 'active':''}`} href={`/interface/hebrew?next=${getCurrentPage()}`}>עברית</a>
<a className={`interfaceLinks-option int-bi int-he ${(currentLang == 'hebrew') ? 'active':''}`} href={`/interface/hebrew?next=${getCurrentPage()}`}>བོད་ཡིག</a>
<a className={`interfaceLinks-option int-bi int-en ${(currentLang == 'english') ? 'active' : ''}`} href={`/interface/english?next=${getCurrentPage()}`}>English</a>
</div>
{ !!translationLanguagePreference ? (
Expand Down
2 changes: 1 addition & 1 deletion static/js/TranslationsBox.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ const TranslationsHeader = () => (
</h3>
<div className="translationsDesc sans-serif">
<InterfaceText>
<EnglishText>Sefaria acquires translations to enrich your learning experience. Preview or choose a different translation below.</EnglishText>
<EnglishText>Pecha acquires translations to enrich your learning experience. Preview or choose a different translation below.</EnglishText>
<HebrewText>ספריא עושה מאמצים להוסיף תרגומים שונים לספרים כדי להעשיר את חווית הלמידה שלכם. כאן ניתן להחליף לתרגום אחר או לראות תצוגה מקדימה שלו לצד הטקסט הנוכחי.</HebrewText>
</InterfaceText>
<a href="/sheets/511573" target="_blank" className="inTextLink">
Expand Down
Loading

0 comments on commit 89b0c87

Please sign in to comment.