-
-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
20 changed files
with
3,427 additions
and
16 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
{ | ||
"id": "AST_LAYOUT_TYPE_CANVAS", | ||
"is_mother": true, | ||
"generate_name": "canvas", | ||
"text": { | ||
"EN": [ | ||
"canvas" | ||
], | ||
"FA": [ | ||
"بوم" | ||
] | ||
}, | ||
"attributes": [ | ||
{ | ||
"id": "AST_LAYOUT_ATTRIBUTE_TYPE_WIDTH", | ||
"generate_name": "width", | ||
"type": "AST_TYPE_NUMBER", | ||
"text": { | ||
"EN": [ | ||
"width" | ||
], | ||
"FA": [ | ||
"عرض" | ||
] | ||
}, | ||
"is_required": false, | ||
"reserved_values": [] | ||
}, | ||
{ | ||
"id": "AST_LAYOUT_ATTRIBUTE_TYPE_HEIGHT", | ||
"generate_name": "height", | ||
"type": "AST_TYPE_NUMBER", | ||
"text": { | ||
"EN": [ | ||
"height" | ||
], | ||
"FA": [ | ||
"ارتفاع" | ||
] | ||
}, | ||
"is_required": false, | ||
"reserved_values": [] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import os | ||
import sys | ||
import json | ||
from pathlib import Path | ||
|
||
parent_dir = Path(__file__).resolve().parent.parent | ||
sys.path.append(str(parent_dir)) | ||
sys.path.append(os.path.join(parent_dir, "data")) | ||
|
||
from type import Type | ||
from lang import Lang | ||
from element import Element | ||
|
||
if __name__ == "__main__": | ||
element = Element() | ||
element.set_is_mother(True) | ||
element.set_generate_name("canvas") | ||
element.set_text(Lang.EN, "canvas") | ||
element.set_text(Lang.FA, "بوم") | ||
|
||
element.add_attribute() \ | ||
.set_generate_name("width") \ | ||
.set_type(Type.Number) \ | ||
.add_text(Lang.EN, "width") \ | ||
.add_text(Lang.FA, "عرض") \ | ||
|
||
element.add_attribute() \ | ||
.set_generate_name("height") \ | ||
.set_type(Type.Number) \ | ||
.add_text(Lang.EN, "height") \ | ||
.add_text(Lang.FA, "ارتفاع") \ | ||
|
||
element_dict = element.to_dict() | ||
|
||
j = json.dumps(element_dict, indent=4, ensure_ascii=False) | ||
print(j) | ||
open(Path(__file__).stem + ".json", "w", encoding="utf-8").write(j) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import os | ||
import sys | ||
import json | ||
from pathlib import Path | ||
|
||
parent_dir = Path(__file__).resolve().parent.parent | ||
sys.path.append(str(parent_dir)) | ||
sys.path.append(os.path.join(parent_dir, "data")) | ||
|
||
from lang import Lang | ||
from element import Element | ||
|
||
if __name__ == "__main__": | ||
element = Element() | ||
element.set_is_mother(True) | ||
element.set_generate_name("caption") | ||
element.set_text(Lang.EN, "caption") | ||
element.set_text(Lang.FA, "سند") | ||
|
||
element_dict = element.to_dict() | ||
|
||
j = json.dumps(element_dict, indent=4, ensure_ascii=False) | ||
print(j) | ||
open(Path(__file__).stem + ".json", "w", encoding="utf-8").write(j) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import os | ||
import sys | ||
import json | ||
from pathlib import Path | ||
|
||
parent_dir = Path(__file__).resolve().parent.parent | ||
sys.path.append(str(parent_dir)) | ||
sys.path.append(os.path.join(parent_dir, "data")) | ||
|
||
from lang import Lang | ||
from element import Element | ||
|
||
if __name__ == "__main__": | ||
element = Element() | ||
element.set_is_mother(True) | ||
element.set_generate_name("cite") | ||
element.set_text(Lang.EN, "cite") | ||
element.set_text(Lang.FA, "ارجاع") | ||
|
||
element_dict = element.to_dict() | ||
|
||
j = json.dumps(element_dict, indent=4, ensure_ascii=False) | ||
print(j) | ||
open(Path(__file__).stem + ".json", "w", encoding="utf-8").write(j) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import os | ||
import sys | ||
import json | ||
from pathlib import Path | ||
|
||
parent_dir = Path(__file__).resolve().parent.parent | ||
sys.path.append(str(parent_dir)) | ||
sys.path.append(os.path.join(parent_dir, "data")) | ||
|
||
from lang import Lang | ||
from element import Element | ||
|
||
if __name__ == "__main__": | ||
element = Element() | ||
element.set_is_mother(True) | ||
element.set_generate_name("code") | ||
element.set_text(Lang.EN, "code") | ||
element.set_text(Lang.FA, "کد") | ||
|
||
element_dict = element.to_dict() | ||
|
||
j = json.dumps(element_dict, indent=4, ensure_ascii=False) | ||
print(j) | ||
open(Path(__file__).stem + ".json", "w", encoding="utf-8").write(j) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import os | ||
import sys | ||
import json | ||
from pathlib import Path | ||
|
||
parent_dir = Path(__file__).resolve().parent.parent | ||
sys.path.append(str(parent_dir)) | ||
sys.path.append(os.path.join(parent_dir, "data")) | ||
|
||
import rels | ||
import targets | ||
import languages | ||
import mediatypes | ||
import referrerpolicies | ||
from lang import Lang | ||
from type import Type | ||
from value import Value | ||
from element import Element | ||
|
||
if __name__ == "__main__": | ||
element = Element() | ||
element.set_is_mother(True) | ||
element.set_generate_name("col") | ||
element.set_text(Lang.EN, "col") | ||
element.set_text(Lang.FA, "کول") | ||
|
||
element.add_attribute() \ | ||
.set_generate_name("span") \ | ||
.set_type(Type.PositiveInt) \ | ||
.add_text(Lang.EN, "span") \ | ||
.add_text(Lang.FA, "اسپن") \ | ||
|
||
element_dict = element.to_dict() | ||
|
||
j = json.dumps(element_dict, indent=4, ensure_ascii=False) | ||
print(j) | ||
open(Path(__file__).stem + ".json", "w", encoding="utf-8").write(j) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import os | ||
import sys | ||
import json | ||
from pathlib import Path | ||
|
||
parent_dir = Path(__file__).resolve().parent.parent | ||
sys.path.append(str(parent_dir)) | ||
sys.path.append(os.path.join(parent_dir, "data")) | ||
|
||
import rels | ||
import targets | ||
import languages | ||
import mediatypes | ||
import referrerpolicies | ||
from lang import Lang | ||
from type import Type | ||
from value import Value | ||
from element import Element | ||
|
||
if __name__ == "__main__": | ||
element = Element() | ||
element.set_is_mother(True) | ||
element.set_generate_name("colgroup") | ||
element.set_text(Lang.EN, "colgroup") | ||
element.set_text(Lang.FA, "کول گروه") | ||
|
||
element.add_attribute() \ | ||
.set_generate_name("span") \ | ||
.set_type(Type.PositiveInt) \ | ||
.add_text(Lang.EN, "count") \ | ||
.add_text(Lang.FA, "تعداد") \ | ||
|
||
element_dict = element.to_dict() | ||
|
||
j = json.dumps(element_dict, indent=4, ensure_ascii=False) | ||
print(j) | ||
open(Path(__file__).stem + ".json", "w", encoding="utf-8").write(j) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import os | ||
import sys | ||
import json | ||
from pathlib import Path | ||
|
||
parent_dir = Path(__file__).resolve().parent.parent | ||
sys.path.append(str(parent_dir)) | ||
sys.path.append(os.path.join(parent_dir, "data")) | ||
|
||
import rels | ||
import targets | ||
import languages | ||
import mediatypes | ||
import referrerpolicies | ||
from lang import Lang | ||
from type import Type | ||
from value import Value | ||
from element import Element | ||
|
||
if __name__ == "__main__": | ||
element = Element() | ||
element.set_is_mother(True) | ||
element.set_generate_name("data") | ||
element.set_text(Lang.EN, "data") | ||
element.set_text(Lang.FA, "داده") | ||
|
||
element.add_attribute() \ | ||
.set_generate_name("value") \ | ||
.set_type(Type.AnyNoEmpty) \ | ||
.add_text(Lang.EN, "value") \ | ||
.add_text(Lang.FA, "مقدار") \ | ||
|
||
element_dict = element.to_dict() | ||
|
||
j = json.dumps(element_dict, indent=4, ensure_ascii=False) | ||
print(j) | ||
open(Path(__file__).stem + ".json", "w", encoding="utf-8").write(j) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import os | ||
import sys | ||
import json | ||
from pathlib import Path | ||
|
||
parent_dir = Path(__file__).resolve().parent.parent | ||
sys.path.append(str(parent_dir)) | ||
sys.path.append(os.path.join(parent_dir, "data")) | ||
|
||
from lang import Lang | ||
from element import Element | ||
|
||
if __name__ == "__main__": | ||
element = Element() | ||
element.set_is_mother(True) | ||
element.set_generate_name("datalist") | ||
element.set_text(Lang.EN, "datalist") | ||
element.set_text(Lang.FA, "لیست داده") | ||
|
||
element_dict = element.to_dict() | ||
|
||
j = json.dumps(element_dict, indent=4, ensure_ascii=False) | ||
print(j) | ||
open(Path(__file__).stem + ".json", "w", encoding="utf-8").write(j) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import os | ||
import sys | ||
import json | ||
from pathlib import Path | ||
|
||
parent_dir = Path(__file__).resolve().parent.parent | ||
sys.path.append(str(parent_dir)) | ||
sys.path.append(os.path.join(parent_dir, "data")) | ||
|
||
from lang import Lang | ||
from element import Element | ||
|
||
if __name__ == "__main__": | ||
element = Element() | ||
element.set_is_mother(True) | ||
element.set_generate_name("dd") | ||
element.set_text(Lang.EN, "dd") | ||
element.set_text(Lang.FA, "دی دی") | ||
|
||
element_dict = element.to_dict() | ||
|
||
j = json.dumps(element_dict, indent=4, ensure_ascii=False) | ||
print(j) | ||
open(Path(__file__).stem + ".json", "w", encoding="utf-8").write(j) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"id": "AST_LAYOUT_TYPE_DEL", | ||
"is_mother": true, | ||
"generate_name": "del", | ||
"text": { | ||
"EN": [ | ||
"del" | ||
], | ||
"FA": [ | ||
"خط خورده" | ||
] | ||
}, | ||
"attributes": [] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import os | ||
import sys | ||
import json | ||
from pathlib import Path | ||
|
||
parent_dir = Path(__file__).resolve().parent.parent | ||
sys.path.append(str(parent_dir)) | ||
sys.path.append(os.path.join(parent_dir, "data")) | ||
|
||
from lang import Lang | ||
from element import Element | ||
|
||
if __name__ == "__main__": | ||
element = Element() | ||
element.set_is_mother(True) | ||
element.set_generate_name("del") | ||
element.set_text(Lang.EN, "del") | ||
element.set_text(Lang.FA, "خط خورده") | ||
|
||
element_dict = element.to_dict() | ||
|
||
j = json.dumps(element_dict, indent=4, ensure_ascii=False) | ||
print(j) | ||
open(Path(__file__).stem + ".json", "w", encoding="utf-8").write(j) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
{ | ||
"id": "AST_LAYOUT_TYPE_DETAILS", | ||
"is_mother": true, | ||
"generate_name": "details", | ||
"text": { | ||
"EN": [ | ||
"details" | ||
], | ||
"FA": [ | ||
"جزییات" | ||
] | ||
}, | ||
"attributes": [ | ||
{ | ||
"id": "AST_LAYOUT_ATTRIBUTE_TYPE_OPEN", | ||
"generate_name": "open", | ||
"type": "AST_TYPE_BOOLEAN", | ||
"text": { | ||
"EN": [ | ||
"open" | ||
], | ||
"FA": [ | ||
"باز" | ||
] | ||
}, | ||
"is_required": false, | ||
"reserved_values": [] | ||
} | ||
] | ||
} |
Oops, something went wrong.