I'm trying to add rounded corner extension in schema but I'm getting an error.
Couldn't invoke: Attempt to invoke virtual method 'java.lang.Class java.lang.reflect.Method.getParameterTypes()' on a null object reference
Here is my schema
{
"name": "Generated Templated",
"metadata-version": 1,
"author": "Schema Listview generator tool",
"platforms": [
"App Inventor",
"Kodular",
"Niotron"
],
"extensions": {
"CornerRadius": "com.sunny.CornerRadius.CornerRadius"
},
"keys": [
"id",
"color"
],
"components": [
{
"id": "ListviewContainer{id}",
"type": "HorizontalArrangement",
"properties": {
"Height": 50,
"Width": -1095
}
},
{
"id": "CornerRadius1{id}",
"type": "com.sunny.CornerRadius.CornerRadius",
"properties": {
"component":"ListviewContainer{id}",
"bgColor": "{color}",
"topLeft": 20,
"topRight":20,
"bottomLeft": 20,
"bottomRight":20
}
}
]
}
Any idea what is wrong? Thanks
TIMAI2
July 13, 2024, 7:41pm
2
Why not create this setup in a project and use the generator:
That's what I did but it only included the extension and didn't add the component to it so I'm trying to figure it out myself
TIMAI2
July 13, 2024, 7:48pm
4
You may need to show your blocks for that then...
Only schema block with the json it works without the extension component
3dmixer:
,
{
"id": "CornerRadius1{id}",
"type": "com.sunny.CornerRadius.CornerRadius",
"properties": {
"component":"ListviewContainer{id}",
"bgColor": "{color}",
"topLeft": 20,
"topRight":20,
"bottomLeft": 20,
"bottomRight":20
}
}
This is where the issue is I think. The type could be the issue
TIMAI2
July 13, 2024, 11:13pm
7
Best i can suggest is to ask here:
🧱 Dynamic Components Extension that supports every component in your AI2 distribution, instead of having pre-defined components. I thought about making a full method to create all dynamic components without creating different blocks for every...
Reading time: 149 mins 🕑
Likes: 2643 ❤
1 Like