mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 12:54:40 +01:00
Fix scope defaults, fix order to int and enforce name to not be empty
This commit is contained in:
parent
362995d5f7
commit
19f84805bd
1 changed files with 11 additions and 4 deletions
|
|
@ -83,14 +83,21 @@ def usd_contribution_layer_types():
|
|||
|
||||
class ContributionLayersModel(BaseSettingsModel):
|
||||
_layout = "compact"
|
||||
name: str = SettingsField(title="Name")
|
||||
name: str = SettingsField(
|
||||
default="",
|
||||
regex="[A-Za-z0-9_-]+",
|
||||
title="Name")
|
||||
scope: list[str] = SettingsField(
|
||||
default_factory=list,
|
||||
title="Scope",
|
||||
enum_resolver=usd_contribution_layer_types)
|
||||
order: str = SettingsField(
|
||||
order: int = SettingsField(
|
||||
default=0,
|
||||
title="Order",
|
||||
description="Higher order means a higher strength and stacks the "
|
||||
"layer on top.")
|
||||
description=(
|
||||
"Higher order means a higher strength and stacks the layer on top."
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
class CollectUSDLayerContributionsProfileModel(BaseSettingsModel):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue