Skip to content

Commit

Permalink
Merge pull request #137 from alpheios-project/incr-3.3.x
Browse files Browse the repository at this point in the history
Incr 3.3.x
  • Loading branch information
balmas authored Mar 12, 2023
2 parents 98fe713 + ab68e5a commit 9f7ff83
Show file tree
Hide file tree
Showing 13 changed files with 5,666 additions and 3,890 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/qa.yml → .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: QA Build
name: Release Build
on:
push:
branches: [ qa ]
branches: [ qa, ftqa, production ]

workflow_dispatch:

Expand Down Expand Up @@ -49,5 +49,5 @@ jobs:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: publish
run: npm publish --tag qa
run: npm publish --tag ${{ steps.run_build.outputs.npmTag }}

39 changes: 39 additions & 0 deletions BUILD.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Alpheios Embedded Library Build Instructions

## Prerequisites:

* Node 14.1.0 or higher, npm 6.14.6 or higher

## Developer Build

```
npm install && npm update
npm run build
npm run dev
```

The last step runs a local web server on port 8888. Load the sample.html file
at the root of the directory. Changes made to the code will be dynamically rebuilt.


## QA Build

1. merge the `master` branch to the `qa` branch and push to GitHub
2. GitHub Actions will execute the release.yml workflow to inject the build number,
install the `qa` branch of the alpheios-components library, build the distribution
files, tag a pre-release in GitHub and publish the alpheios-embedded package to
npm tagged as `@qa`


## Production Build and Version

1. merge the `qa` branch to the `production` branch (but don't push it)
2. Edit version in the package.json.
3. Commit and push the change to GitHub.
4. GitHub Actions will execute the release.yml workflow to inject the build number,
install the `production` branch of the alpheios-components library, build the distribution
files, tag a pre-release in GitHub and publish the alpheios-embedded package to
npm tagged as `@rc`
5. When ready to release the code, manually tag the npm package as `@latest` using
`npm --dist-tag` and remove the "Pre-release" flag from the Release in GitHub.
6. Merge the version and any other code changes from `production` back to `master`
26 changes: 1 addition & 25 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -373,28 +373,4 @@ See our [FAQ pages](http://www.alpheios.net/pages/faq/)

## Developer Instructions

### Prerequisites to build the Alpheios Embedded Library from source:

* Node 13.7.0 or higher

### Install Dependencies

```
npm install
```

### Build

```
npm run test
npm run build
```

### Develop

```
npm run dev
```

Runs a local web server on port 8888. Load the sample.html file at the root of the directory. Changes made to the
code will be dynamically rebuilt.
See [BUILD.md](BUILD.md)
120 changes: 120 additions & 0 deletions demo/index-detect.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
<!-- Basic Development demo, using Components from the CDN -->
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Alpheios Embedded Library Developer Test Page</title>
<link rel="stylesheet" href="../dist/style/style-components.css"/>
<script src="https://cdn.auth0.com/js/lock/11.14.0/lock.js"></script>
<script src="../dist/auth0/env-embed.js"></script>
<style>
.customenabled {
color: green;
}
.customdisabled {
color: red;
}

</style>
</head>

<body>
<script type="text/javascript">
document.addEventListener("DOMContentLoaded", function(event) {
import ('../dist/alpheios-embedded.js').then(embedLib => {
window.AlpheiosEmbed.importDependencies({ mode: 'development' }).then(Embedded => {
new Embedded(
{
clientId: 'embed-lib-index-demo',
authEnv: auth0Env,
disabledSelector:".customignore",
enabledClass: 'customenabled',
disabledClass: 'customdisabled',
popupInitialPos: {
left: '150px',
top: '150px'
},
toolbarInitialPos: {
top: '5vh',
right: '5vw'
},
}).activate();
}).catch(e => {
console.error(`Import of an embedded library dependencies failed: ${e}`)
})
}).catch(e => {
console.error(`Import of an embedded library failed: ${e}`)
})
});
</script>
<h4>Greek</h4>
<div class="alpheios-enabled" id="block1">
<p>τά ταῖν ταῖν τοῦ</p>
<p>εγώ εμένα ἐμαυτοῦ ταύταις</p>
<p>ένα δύο τρία</p>
<p>όμορφος νέος γλυκός</p>
<p>συνεχής πλατύς οξύς</p>
<p>ἄνδρα μοι ἔννεπε, μοῦσα, πολύτροπον</p>
<p>πρόσφυμα ξηρή </p>
<p>σκληρή ζώνη ινώδους συνδετικού ιστού που συνδέει συνήθως μύες με οστά</p>
<p>A word with missing gender: ἥρωϊ</p>
<p>Δαναὸς ἀφίκτωρ λεπτοψαμάθων</p>
</div>

<h4>Latin</h4>
<div class="alpheios-enabled" id="block2">
<p>fero ferre tuli latus ferant missing-word</p>
<p>sum sunt</p>
<p>mare cupidinibus cepit differ</p>
<p>a bene placito</p>
<p>ab ovo usque ad mala</p>
<p>caeli beatum videre</p>
<p class="customignore">Ignore This</p>
</div>

<h4>Arabic</h4>
<div class="alpheios-enabled" id="block3" dir="rtl">
1 اَلدٌّنيَا دَارُ مَمَرٍ لاَ دَارُ مَقَرٍ * سُلطَان بِلاَ عَدلٍ كَنَهرٍ
</div>

<h4>Persian</h4>
<div class="alpheios-enabled" id="block4" dir="rtl">
آبادائیدن
به نام خداوند جان و خرد
کزین برتر اندیشه برنگذرد
خداوند نام و خداوند جای
خداوند روزی ده رهنمای
خداوند کیوان و گردان سپهر
فروزنده ماه و ناهید و مهر
ز نام و نشان و گمان برترست
نگارندهٔ بر شده پیکرست
به بینندگان آفریننده را
نبینی مرنجان دو بیننده را
نیابد بدو نیز اندیشه راه
که او برتر از نام و از جایگاه
سخن هر چه زین گوهران بگذرد
نیابد بدو راه جان و خرد
</div>

<h4>Ge'ez</h4>
<div class="alpheios-enabled" id="block5" dir="ltr">
ይትባረክ፡ እግዚአብሔር፡ አምላከ፡ እስራኤል፡ አምላክ፡ ለኵሉ፡ መንፈስ፡ ወለኵሉ፡ ዘሥጋ፡ ወይቤሎ፡ እግዚአብሔር፡ ለእዝራ፡ አእምር፡ ወጠይቅ፡
</div>

<h4>Traditional Chinese</h4>
<div class="alpheios-enabled" id="block6" dir="ltr">
天地玄黃,宇宙洪荒。日月盈昃,辰宿列張。寒來暑往,秋收冬藏。閏余成歲,律呂調陽。
</div>

<h4>Simplified Chinese</h4>
<div class="alpheios-enabled" id="block7" dir="ltr">
天地玄黄,宇宙洪荒。日月盈昃,辰宿列张。寒来暑往,秋收冬藏。闰余成岁,律吕调阳。
</div>

<h4>Chinese Test cases</h4>
<div class="alpheios-enabled" dir="ltr">
子曰學
</div>
</body>
</html>
55 changes: 55 additions & 0 deletions demo/index-paideia.html

Large diffs are not rendered by default.

9 changes: 9 additions & 0 deletions demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,14 @@
disabledSelector:".customignore",
enabledClass: 'customenabled',
disabledClass: 'customdisabled',
languageOptions: {
lexiconsShort: {
lat: [ 'https://github.com/alpheios-project/paidea-glossary' ]
}
},
uiOptions: {
hidePopupOnClickAway: true
},
popupInitialPos: {
left: '150px',
top: '150px'
Expand Down Expand Up @@ -59,6 +67,7 @@ <h4>Greek</h4>
<p>πρόσφυμα ξηρή </p>
<p>σκληρή ζώνη ινώδους συνδετικού ιστού που συνδέει συνήθως μύες με οστά</p>
<p>A word with missing gender: ἥρωϊ</p>
<p>Δαναὸς ἀφίκτωρ λεπτοψαμάθων</p>
</div>

<h4>Latin</h4>
Expand Down
Loading

0 comments on commit 9f7ff83

Please sign in to comment.