Coverage for gws-app/gws/plugin/model_widget/feature_select/__init__.py: 91%

11 statements  

« prev     ^ index     » next       coverage.py v7.11.0, created at 2025-10-16 23:09 +0200

1"""Feature select widget.""" 

2 

3import gws 

4import gws.base.model.widget 

5 

6gws.ext.new.modelWidget('featureSelect') 

7 

8 

9class Config(gws.base.model.widget.Config): 

10 """Feature select widget configuration.""" 

11 

12 withSearch: bool = False 

13 """Enable search functionality in the widget.""" 

14 

15 

16class Props(gws.base.model.widget.Props): 

17 withSearch: bool 

18 

19 

20class Object(gws.base.model.widget.Object): 

21 def props(self, user): 

22 return gws.u.merge( 

23 super().props(user), 

24 withSearch=self.cfg('withSearch', default=False), 

25 )