@24i/bigscreen-sdk 1.0.30-alpha.2517 → 1.0.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@24i/bigscreen-sdk",
3
- "version": "1.0.30-alpha.2517",
3
+ "version": "1.0.30",
4
4
  "description": "SmartApps BIGscreen SDK monorepo",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -23,6 +23,10 @@
23
23
  padding-bottom: $keyboard-padding-bottom;
24
24
  height: 100%;
25
25
  width: 100%;
26
+
27
+ &.wide .key.key-space {
28
+ width: $key-space-wide-width;
29
+ }
26
30
  }
27
31
 
28
32
  .keys-container {
@@ -208,6 +208,7 @@ export class Keyboard extends KeyboardBase<Layouts, Props> {
208
208
 
209
209
  renderKeyboard(layout: JSX.Element[]) {
210
210
  const { texts, shouldHideOnBackdropClick, languageLayout } = this.props;
211
+ const layoutClassName = languageLayout?.className || '';
211
212
  const isSpecialLayout = this.renderedLayout === 'special';
212
213
  const isNormalLayout = this.renderedLayout === 'normal';
213
214
  return (
@@ -216,7 +217,7 @@ export class Keyboard extends KeyboardBase<Layouts, Props> {
216
217
  onClick={() => this.onCancel()}
217
218
  enableOnClick={shouldHideOnBackdropClick}
218
219
  />
219
- <div className="keyboard-wrapper">
220
+ <div className={`keyboard-wrapper ${layoutClassName}`}>
220
221
  <div className="keys-container side-bar layout-selector">
221
222
  <div className="key-row first-row">
222
223
  <div className="key key-wide key-empty">&nbsp;</div>
@@ -26,6 +26,7 @@ $icon-mask-size: 40px;
26
26
  $key-with-icon-padding: 17px 22px;
27
27
 
28
28
  $key-space-width: 528px;
29
+ $key-space-wide-width: 609px;
29
30
 
30
31
  $focus-shadow-1: 0 1px 3px 0;
31
32
  $focus-shadow-2: 0 20px 32px 0;
@@ -26,6 +26,7 @@ $icon-mask-size: 27px;
26
26
  $key-with-icon-padding: 11px 15px;
27
27
 
28
28
  $key-space-width: 348px;
29
+ $key-space-wide-width: 406px;
29
30
 
30
31
  $focus-shadow-1: 0 1px 2px 0;
31
32
  $focus-shadow-2: 0 13px 21px 0;
@@ -1,3 +1,8 @@
1
1
  export { hebrew } from './hebrew';
2
+ export { korean } from './korean';
2
3
  export { latin } from './latin';
4
+ export { russian } from './russian';
3
5
  export { special } from './special';
6
+ export { tibetan } from './tibetan';
7
+ export { turkish } from './turkish';
8
+ export { urdu } from './urdu';
@@ -0,0 +1,26 @@
1
+ /* eslint-disable no-magic-numbers */
2
+ import { KeyMatrixCell } from '../../types';
3
+
4
+ const keyboardLayout = [
5
+ ['1', '2', '3', '4', '5', '6', '7', '8', '9', '0'],
6
+ ['ᄀ', 'ᄂ', 'ᄃ', 'ᄅ', 'ᄆ', 'ᄇ', 'ᄉ', 'ᄋ', 'ᄌ', 'ᄎ'],
7
+ ['ᄏ', 'ᄐ', 'ᄑ', 'ᄒ', 'ᅡ', 'ᅣ', 'ᅥ', 'ᅧ', 'ᅩ', 'ᅭ'],
8
+ ['ᅮ', 'ᅲ', 'ᅳ', 'ᅵ', '?', ',', '.', '@', '-', '_'],
9
+ ];
10
+
11
+ /* eslint-disable max-len */
12
+ const makeFocusStrings = (layout: KeyMatrixCell[][], hasLanguageLayout: boolean) => [
13
+ ['', '', '', ...layout[0], '', 'backspace', 'backspace'],
14
+ ['abc', 'abc', ...layout[1], 'clear', 'clear'],
15
+ ['special', 'special', ...layout[2], 'left', 'right'],
16
+ ['', '', ...layout[3], '', ''],
17
+ [
18
+ ...(hasLanguageLayout ? ['language', 'language'] : ['', '']),
19
+ 'shift', 'shift', 'space', 'space', 'space', 'space', 'space', 'space', 'domain', 'domain', 'continue', 'continue'],
20
+ ];
21
+
22
+ export const korean = {
23
+ keyText: 'ᄀᄂᄃ',
24
+ layout: keyboardLayout,
25
+ makeFocusStrings,
26
+ };
@@ -0,0 +1,27 @@
1
+ /* eslint-disable no-magic-numbers */
2
+ import { KeyMatrixCell } from '../../types';
3
+
4
+ const keyboardLayout = [
5
+ ['1', '2', '3', '4', '5', '6', '7', '8', '9', '0', '.'],
6
+ ['a', 'б', 'в', 'г', 'д', 'е', 'ё', 'ж', 'з', 'и', 'й'],
7
+ ['к', 'л', 'м', 'н', 'о', 'п', 'р', 'с', 'т', 'у', 'ф'],
8
+ ['х', 'ц', 'ч', 'ш', 'щ', 'ъ', 'ы', 'ь', 'э', 'ю', 'я'],
9
+ ];
10
+
11
+ /* eslint-disable max-len */
12
+ const makeFocusStrings = (layout: KeyMatrixCell[][], hasLanguageLayout: boolean) => [
13
+ ['', '', ...layout[0], 'backspace', 'backspace'],
14
+ ['abc', 'abc', ...layout[1], 'clear', 'clear'],
15
+ ['special', 'special', ...layout[2], 'left', 'right'],
16
+ ['', '', ...layout[3], '', ''],
17
+ [
18
+ ...(hasLanguageLayout ? ['language', 'language'] : ['', '']),
19
+ 'shift', 'shift', 'space', 'space', 'space', 'space', 'space', 'space', 'space', 'domain', 'domain', 'continue', 'continue'],
20
+ ];
21
+
22
+ export const russian = {
23
+ className: 'wide',
24
+ keyText: 'абв',
25
+ layout: keyboardLayout,
26
+ makeFocusStrings,
27
+ };
@@ -0,0 +1,26 @@
1
+ /* eslint-disable no-magic-numbers */
2
+ import { KeyMatrixCell } from '../../types';
3
+
4
+ const keyboardLayout = [
5
+ ['༡', '༢', '༣', '༤', '༥', '༦', '༧', '༨', '༩', '༠'],
6
+ ['ཀ', 'ཁ', 'ག ', 'ང ', 'ཅ ', 'ཆ', 'ཇ', 'ཉ', 'ཏ', 'ཐ'],
7
+ ['ད', 'ན', 'པ', 'ཕ', 'བ', 'མ', 'ཙ', 'ཚ', 'ཛ', 'ཝ'],
8
+ ['ཝ', 'ཟ', 'འ', 'ཡ', 'ར', 'ལ', 'ཤ', 'ས', 'ཧ', 'ཨ'],
9
+ ];
10
+
11
+ /* eslint-disable max-len */
12
+ const makeFocusStrings = (layout: KeyMatrixCell[][], hasLanguageLayout: boolean) => [
13
+ ['', '', '', ...layout[0], '', 'backspace', 'backspace'],
14
+ ['abc', 'abc', ...layout[1], 'clear', 'clear'],
15
+ ['special', 'special', ...layout[2], 'left', 'right'],
16
+ ['', '', ...layout[3], '', ''],
17
+ [
18
+ ...(hasLanguageLayout ? ['language', 'language'] : ['', '']),
19
+ 'shift', 'shift', 'space', 'space', 'space', 'space', 'space', 'space', 'domain', 'domain', 'continue', 'continue'],
20
+ ];
21
+
22
+ export const tibetan = {
23
+ keyText: 'ཀཁག',
24
+ layout: keyboardLayout,
25
+ makeFocusStrings,
26
+ };
@@ -0,0 +1,26 @@
1
+ /* eslint-disable no-magic-numbers */
2
+ import { KeyMatrixCell } from '../../types';
3
+
4
+ const keyboardLayout = [
5
+ ['1', '2', '3', '4', '5', '6', '7', '8', '9', '0'],
6
+ ['a', 'b', 'c', 'ç', 'd', 'e', 'f', 'g', 'ğ', 'h'],
7
+ ['ı', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'ö', 'p'],
8
+ ['r', 's', 'ş', 't', 'u', 'ü', 'v', 'y', 'z', '.'],
9
+ ];
10
+
11
+ /* eslint-disable max-len */
12
+ const makeFocusStrings = (layout: KeyMatrixCell[][], hasLanguageLayout: boolean) => [
13
+ ['', '', ...layout[0], 'backspace', 'backspace'],
14
+ ['abc', 'abc', ...layout[1], 'clear', 'clear'],
15
+ ['special', 'special', ...layout[2], 'left', 'right'],
16
+ ['', '', ...layout[3], '', ''],
17
+ [
18
+ ...(hasLanguageLayout ? ['language', 'language'] : ['', '']),
19
+ 'shift', 'shift', 'space', 'space', 'space', 'space', 'space', 'space', 'domain', 'domain', 'continue', 'continue'],
20
+ ];
21
+
22
+ export const turkish = {
23
+ keyText: 'Abc',
24
+ layout: keyboardLayout,
25
+ makeFocusStrings,
26
+ };
@@ -0,0 +1,26 @@
1
+ /* eslint-disable no-magic-numbers */
2
+ import { KeyMatrixCell } from '../../types';
3
+
4
+ const keyboardLayout = [
5
+ ['1', '2', '3', '4', '5', '6', '7', '8', '9', '0'],
6
+ ['الف', 'ب', 'س', 'ڈ', 'ای', 'ایف', 'جی', 'ح', 'آئی', 'ج'],
7
+ ['ک', 'ل', 'م', 'ن', 'او', 'پ', 'کیو', 'ر', 'ایس', 'ٹ'],
8
+ ['یو', 'وی', 'ڈبلیو', 'ایکس', 'یے', 'ز', 'ڈاٹ', 'ایٹ', '-', '_'],
9
+ ];
10
+
11
+ /* eslint-disable max-len */
12
+ const makeFocusStrings = (layout: KeyMatrixCell[][], hasLanguageLayout: boolean) => [
13
+ ['', '', ...layout[0], 'backspace', 'backspace'],
14
+ ['abc', 'abc', ...layout[1], 'clear', 'clear'],
15
+ ['special', 'special', ...layout[2], 'left', 'right'],
16
+ ['', '', ...layout[3], '', ''],
17
+ [
18
+ ...(hasLanguageLayout ? ['language', 'language'] : ['', '']),
19
+ 'shift', 'shift', 'space', 'space', 'space', 'space', 'space', 'space', 'domain', 'domain', 'continue', 'continue'],
20
+ ];
21
+
22
+ export const urdu = {
23
+ keyText: 'دوبارہ سے',
24
+ layout: keyboardLayout,
25
+ makeFocusStrings,
26
+ };
@@ -13,6 +13,7 @@ export type KeyTexts = {
13
13
  };
14
14
 
15
15
  export type LanguageLayout = {
16
+ className? : string,
16
17
  keyText: KeyTexts['toNormalLayout'],
17
18
  layout: KeyMatrixCell[][],
18
19
  makeFocusStrings: (layout: KeyMatrixCell[][], hasLanguageLayout: boolean) => KeyMatrixCell[][],