File tree Expand file tree Collapse file tree 1 file changed +5
-0
lines changed
Expand file tree Collapse file tree 1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -84,6 +84,9 @@ func _enter_tree():
8484 if ! visibility_changed .is_connected (update_display_mode ):
8585 visibility_changed .connect (update_display_mode )
8686
87+ func _ready ():
88+ indicate_required ()
89+
8790## Update label display mode based on visibility
8891## If the label is visible and the mode is either Mode.IN_INPUT or Mode.HIDDEN, the mode is set to Mode.SEPARATE.
8992## If the label is not visible and the mode is Mode.SEPARATE, the mode is set to Mode.HIDDEN.
@@ -99,6 +102,8 @@ func update_display_mode():
99102
100103## Add or remove the required_hint if input_required
101104func indicate_required ():
105+ if ! is_node_ready ():
106+ return
102107 # if * needed but not present
103108 if input_required :
104109 if required_hint not in ["" , null ]&& ! text .ends_with (required_hint ):
You can’t perform that action at this time.
0 commit comments