Skip to content

Commit 9774149

Browse files
committed
latte: info about constants
1 parent 8b4159b commit 9774149

17 files changed

+204
-0
lines changed

latte/bg/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ abbreviated: {var $arr = [hello, btn--default, €]}
205205
И не трябва да се припокрива с ключовите думи `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Константи .[#toc-constants]
209+
---------------------------
210+
211+
Тъй като кавичките могат да бъдат пропуснати при обикновените низове, препоръчваме да записвате глобалните константи с наклонена черта в началото, за да ги различавате:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Този запис е напълно валиден в самия PHP, където наклонената черта показва, че константата е в глобалното пространство от имена.
218+
219+
208220
Кратък троен оператор .[#toc-short-ternary-operator]
209221
----------------------------------------------------
210222

latte/cs/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ Nesmí být tvořeny pouze velkými písmeny a podtržítky, protože ty jsou po
205205
Také nesmí kolidovat s klíčovými slovy: `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Konstanty
209+
---------
210+
211+
Jelikož lze u jednoduchých řetězců vynechávat uvozovky, doporučujeme pro odlišení zapisovat globální konstanty s lomítkem na začátku:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Tento zápis je zcela validní v samotném PHP, lomítko říká, že konstanta je v globálním namespace.
218+
219+
208220
Zkrácený ternární operátor
209221
--------------------------
210222

latte/de/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ Sie darf nicht nur aus Großbuchstaben und Unterstrichen bestehen, denn dann gil
205205
Und er darf nicht mit den Schlüsselwörtern `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor` kollidieren.
206206

207207

208+
Konstanten .[#toc-constants]
209+
----------------------------
210+
211+
Da Anführungszeichen bei einfachen Zeichenketten weggelassen werden können, empfiehlt es sich, globale Konstanten mit einem Schrägstrich am Anfang zu schreiben, um sie zu unterscheiden:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Diese Schreibweise ist in PHP selbst vollständig gültig, wo der Schrägstrich anzeigt, dass die Konstante im globalen Namensraum liegt.
218+
219+
208220
Kurzer ternärer Operator .[#toc-short-ternary-operator]
209221
-------------------------------------------------------
210222

latte/el/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ abbreviated: {var $arr = [hello, btn--default, €]}
205205
Και δεν πρέπει να συγκρούεται με τις λέξεις-κλειδιά `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Σταθερές .[#toc-constants]
209+
--------------------------
210+
211+
Δεδομένου ότι τα εισαγωγικά μπορούν να παραλειφθούν με απλές συμβολοσειρές, συνιστούμε να γράφετε τις παγκόσμιες σταθερές με μια κάθετο στην αρχή για να τις διαφοροποιήσετε:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Αυτός ο συμβολισμός είναι απολύτως έγκυρος στην ίδια την PHP, όπου η κάθετος υποδεικνύει ότι η σταθερά βρίσκεται στον παγκόσμιο χώρο ονομάτων.
218+
219+
208220
Σύντομος τριμερής τελεστής .[#toc-short-ternary-operator]
209221
---------------------------------------------------------
210222

latte/en/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ It must not be composed of only uppercase letters and underscores, because then
205205
And it must not collide with the keywords `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Constants
209+
---------
210+
211+
Since quotes can be omitted with simple strings, we recommend writing global constants with a slash at the beginning to differentiate them:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
This notation is completely valid in PHP itself, where the slash indicates that the constant is in the global namespace.
218+
219+
208220
Short Ternary Operator
209221
----------------------
210222

latte/es/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ No debe estar compuesto únicamente por letras mayúsculas y guiones bajos, porq
205205
Y no debe colisionar con las palabras clave `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Constantes .[#toc-constants]
209+
----------------------------
210+
211+
Dado que las comillas pueden omitirse con cadenas simples, recomendamos escribir las constantes globales con una barra al principio para diferenciarlas:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Esta notación es completamente válida en el propio PHP, donde la barra indica que la constante está en el espacio de nombres global.
218+
219+
208220
Operador ternario corto .[#toc-short-ternary-operator]
209221
------------------------------------------------------
210222

latte/fr/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ Elle ne doit pas être composée uniquement de lettres majuscules et de traits d
205205
Et il ne doit pas entrer en collision avec les mots-clés `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Constantes .[#toc-constants]
209+
----------------------------
210+
211+
Comme les guillemets peuvent être omis avec de simples chaînes de caractères, nous recommandons d'écrire les constantes globales avec une barre oblique au début pour les différencier :
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Cette notation est tout à fait valide en PHP, où la barre oblique indique que la constante se trouve dans l'espace de noms global.
218+
219+
208220
Opérateur ternaire court .[#toc-short-ternary-operator]
209221
-------------------------------------------------------
210222

latte/hu/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ Nem állhat csak nagybetűkből és aláhúzásokból, mert akkor konstansnak mi
205205
És nem ütközhet a `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor` kulcsszavakkal.
206206

207207

208+
Állandók .[#toc-constants]
209+
--------------------------
210+
211+
Mivel az idézőjelek elhagyhatók az egyszerű karakterláncoknál, javasoljuk, hogy a globális konstansokat a megkülönböztetésük érdekében írjuk le úgy, hogy az elejükön egy slash álljon:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Ez a jelölés teljesen érvényes magában a PHP-ben, ahol a perjel azt jelzi, hogy a konstans a globális névtérben van.
218+
219+
208220
Rövid hármas operátor .[#toc-short-ternary-operator]
209221
----------------------------------------------------
210222

latte/it/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ Non deve essere composta solo da lettere maiuscole e trattini bassi, perché in
205205
E non deve collidere con le parole chiave `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Costanti .[#toc-constants]
209+
--------------------------
210+
211+
Poiché le virgolette possono essere omesse con le stringhe semplici, si consiglia di scrivere le costanti globali con una barra all'inizio per differenziarle:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Questa notazione è completamente valida in PHP, dove lo slash indica che la costante è nello spazio dei nomi globale.
218+
219+
208220
Operatore ternario breve .[#toc-short-ternary-operator]
209221
-------------------------------------------------------
210222

latte/ja/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ abbreviated: {var $arr = [hello, btn--default, €]}
205205
また、キーワード`and`,`array`,`clone`,`default`,`false`,`in`,`instanceof`,`new`,`null`,`or`,`return`,`true`,`xor` と衝突してはいけません。
206206

207207

208+
定数 .[#toc-constants]
209+
--------------------
210+
211+
単純な文字列では引用符を省略することができるので、グローバル定数を区別するために先頭にスラッシュをつけて記述することをお勧めします:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
この記法はPHP自身でも完全に有効で、スラッシュは定数がグローバル名前空間にあることを示します。
218+
219+
208220
短い三項演算子 .[#toc-short-ternary-operator]
209221
--------------------------------------
210222

latte/pl/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ Nie może składać się tylko z wielkich liter i podkreślników, bo wtedy jest
205205
I nie może być sprzeczny z następującymi słowami kluczowymi: `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Stałe .[#toc-constants]
209+
-----------------------
210+
211+
Ponieważ cudzysłowy można pominąć w przypadku prostych ciągów znaków, zalecamy zapisywanie stałych globalnych z ukośnikiem na początku w celu ich rozróżnienia:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Ta notacja jest całkowicie poprawna w samym PHP, gdzie ukośnik wskazuje, że stała znajduje się w globalnej przestrzeni nazw.
218+
219+
208220
Skrócony operator trójskładnikowy .[#toc-short-ternary-operator]
209221
----------------------------------------------------------------
210222

latte/pt/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ Não devem ser compostas apenas de letras maiúsculas e sublinhados, pois então
205205
E não deve colidir com as palavras-chave `and`, `array`, `clone`, `false`, `default`, , `in`, `instanceof`, `new`, `null`, `or`, , `return`, `true`, `xor`.
206206

207207

208+
Constantes .[#toc-constants]
209+
----------------------------
210+
211+
Como as aspas podem ser omitidas com cadeias de caracteres simples, recomendamos escrever as constantes globais com uma barra no início para diferenciá-las:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Essa notação é totalmente válida no próprio PHP, onde a barra indica que a constante está no namespace global.
218+
219+
208220
Operador de Ternary curto .[#toc-short-ternary-operator]
209221
--------------------------------------------------------
210222

latte/ro/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ Nu trebuie să fie compuse numai din litere majuscule și liniuțe de subliniere
205205
Și nu trebuie să intre în coliziune cu cuvintele-cheie `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Constante .[#toc-constants]
209+
---------------------------
210+
211+
Deoarece ghilimelele pot fi omise cu șiruri simple, recomandăm scrierea constantelor globale cu o bară oblică la început pentru a le diferenția:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Această notație este complet valabilă în PHP însuși, unde bara oblică indică faptul că constanta este în spațiul de nume global.
218+
219+
208220
Operator ternar scurt .[#toc-short-ternary-operator]
209221
----------------------------------------------------
210222

latte/ru/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ abbreviated: {var $arr = [hello, btn--default, €]}
205205
И он не должен пересекаться с ключевыми словами `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Константы .[#toc-constants]
209+
---------------------------
210+
211+
Поскольку в простых строках кавычки могут быть опущены, мы рекомендуем писать глобальные константы с косой чертой в начале, чтобы различать их:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Это обозначение вполне допустимо в самом PHP, где косая черта указывает на то, что константа находится в глобальном пространстве имен.
218+
219+
208220
Короткий тернарный оператор .[#toc-short-ternary-operator]
209221
----------------------------------------------------------
210222

latte/sl/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ Ne smejo biti sestavljeni samo iz velikih črk in podčrtajev, ker se potem šte
205205
In ne sme biti v koliziji s ključnimi besedami `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Konstante .[#toc-constants]
209+
---------------------------
210+
211+
Ker lahko pri preprostih nizih izpustite narekovaje, priporočamo, da globalne konstante zapišete s poševnico na začetku, da jih ločite:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Ta zapis je popolnoma veljaven v samem jeziku PHP, kjer poševnica označuje, da je konstanta v globalnem imenskem prostoru.
218+
219+
208220
Kratek terminarni operator .[#toc-short-ternary-operator]
209221
---------------------------------------------------------
210222

latte/tr/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ Yalnızca büyük harflerden ve alt çizgilerden oluşmamalıdır, çünkü o za
205205
Ve `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor` anahtar kelimeleriyle çakışmamalıdır.
206206

207207

208+
Sabitler .[#toc-constants]
209+
--------------------------
210+
211+
Tırnak işaretleri basit dizelerle atlanabildiğinden, global sabitleri ayırt etmek için başında eğik çizgi ile yazmanızı öneririz:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Bu gösterim PHP'nin kendisinde tamamen geçerlidir, burada eğik çizgi sabitin global isim alanında olduğunu gösterir.
218+
219+
208220
Kısa Üçlü Operatör .[#toc-short-ternary-operator]
209221
-------------------------------------------------
210222

latte/uk/syntax.texy

+12
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,18 @@ abbreviated: {var $arr = [hello, btn--default, €]}
205205
І він не повинен перетинатися з ключовими словами `and`, `array`, `clone`, `default`, `false`, `in`, `instanceof`, `new`, `null`, `or`, `return`, `true`, `xor`.
206206

207207

208+
Константи .[#toc-constants]
209+
---------------------------
210+
211+
Оскільки лапки можна опускати для простих рядків, ми рекомендуємо писати глобальні константи зі скісною рискою на початку, щоб відрізняти їх:
212+
213+
```latte
214+
{if \PROJECT_ID === 1} ... {/if}
215+
```
216+
217+
Таке позначення повністю прийнятне і в самому PHP, де коса риска вказує на те, що константа знаходиться у глобальному просторі імен.
218+
219+
208220
Короткий тернарний оператор .[#toc-short-ternary-operator]
209221
----------------------------------------------------------
210222

0 commit comments

Comments
 (0)