boneIO 1.2.0.dev21__tar.gz → 1.2.0.dev23__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {boneio-1.2.0.dev21/boneio.egg-info → boneio-1.2.0.dev23}/PKG-INFO +1 -1
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/cover/cover.py +29 -6
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/cover/time_based.py +3 -3
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/const.py +1 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/covers.py +22 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/display/oled.py +254 -7
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/schema/actions.yaml +13 -1
- boneio-1.2.0.dev23/boneio/version.py +2 -0
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/cssMode-B9wgS3nc.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/cssMode-CNfUxfgr.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/freemarker2-BWuFrqIE.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/freemarker2-DWjclh22.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/handlebars-v7145UWi.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/handlebars-i2k_xWAf.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/html-CcwKUEPK.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/html-5waqLOui.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/htmlMode-BSmyjXrA.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/htmlMode-Bwf-0-Bn.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/index-B6BS4-3O.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/index-CRX9Ew8L.js +5 -5
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/javascript-BPdWBFmL.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/javascript-Kj8C4y4i.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/jsonMode-CFXuuy9f.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/jsonMode-CHLWjsUA.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/liquid-CFKk38kG.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/liquid-3gxkDJwa.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/mdx-BNyJdH4w.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/mdx-CvlTe6nf.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/python-D_-BuVF5.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/python-BK_KcnMp.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/razor-DYq6eRVD.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/razor-DiDDF06t.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/tsMode-DwwcYdMs.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/tsMode-B_ZhXLqZ.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/typescript-6vakCrf3.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/typescript-FjIJU2QD.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/xml-DfD5mx75.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/xml-DiHsfIX6.js +1 -1
- boneio-1.2.0.dev21/boneio/webui/frontend-dist/assets/yaml-MkFkM5Hn.js → boneio-1.2.0.dev23/boneio/webui/frontend-dist/assets/yaml-GoVS_T5n.js +1 -1
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/index.html +1 -1
- {boneio-1.2.0.dev21/boneio/webui → boneio-1.2.0.dev23/boneio/webui/frontend-dist}/schema/binary_sensor.schema.json +20 -0
- {boneio-1.2.0.dev21/boneio/webui → boneio-1.2.0.dev23/boneio/webui/frontend-dist}/schema/config.schema.json +90 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/event.schema.json +70 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/sw.js +1 -1
- {boneio-1.2.0.dev21/boneio/webui/frontend-dist → boneio-1.2.0.dev23/boneio/webui}/schema/binary_sensor.schema.json +20 -0
- {boneio-1.2.0.dev21/boneio/webui/frontend-dist → boneio-1.2.0.dev23/boneio/webui}/schema/config.schema.json +90 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/event.schema.json +70 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23/boneio.egg-info}/PKG-INFO +1 -1
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio.egg-info/SOURCES.txt +16 -16
- boneio-1.2.0.dev21/boneio/version.py +0 -2
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/LICENSE +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/MANIFEST.in +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/README.md +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.2/input.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.2/output_24_16.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.2/output_32_10.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.2/output_32_5.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.2/output_cover.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.2/output_cover_mix.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.3/input.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.3/output_24_16.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.3/output_32_10.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.3/output_32_5.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.3/output_cover.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.3/output_cover_mix.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.4/input.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.4/output_24_16.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.4/output_32_10.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.4/output_32_5.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.4/output_cover.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.4/output_cover_mix.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.5/input.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.5/output_24_16.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.5/output_32_10.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.5/output_cover.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.5/output_cover_mix.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.6/input.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.6/output_24_16.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.6/output_32_10.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.6/output_cover.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.6/output_cover_mix.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.7/input.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.7/output_24_16.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.7/output_32_10.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.7/output_cover.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.7/output_cover_mix.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.8/input.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.8/output_24_16.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.8/output_32_10.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.8/output_cover.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/boards/0.8/output_cover_mix.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/bonecli.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/cover/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/cover/venetian.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/group/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/group/output_group.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/input/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/input/binary_sensor.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/input/detectors.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/input/event.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/output/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/output/basic.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/output/mcp.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/output/pca.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/output/pcf.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/sensor/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/sensor/virtual_energy.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/template/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/template/alarm_panel.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/template/gate_cover.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/components/template/thermostat.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/cloud/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/cloud/data/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/cloud/data/docker-compose-cloud.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/cloud/data/docker-compose.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/cloud/data/init-certs-cloud.sh +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/cloud/registration.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/cloud/secrets.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/config/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/config/config_helper.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/config/migrations/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/config/migrations/v1_proxy_port.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/config/migrations/v2_transition.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/config/package-lock.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/config/package.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/config/schema_converter.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/config/yaml_util.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/discovery.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/events/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/events/bus.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/display.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/inputs.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/manager.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/modbus.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/outputs.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/remote.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/sensors.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/templates/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/templates/alarm.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/templates/gate_cover.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/templates/thermostat.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/templates.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/manager/update.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/messaging/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/messaging/basic.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/messaging/basic_mqtt.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/messaging/local.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/messaging/mqtt.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/messaging/queue.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/remote/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/remote/base.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/remote/esphome.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/remote/mqtt.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/remote/wled.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/sensor/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/sensor/base.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/sensor/system.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/state/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/state/manager.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/system/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/system/host_data.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/system/monitor.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/utils/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/utils/async_updater.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/utils/filter.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/utils/font_util.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/utils/logger.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/utils/timeperiod.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/core/utils/util.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/24x16/adc.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/24x16/binary_sensor.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/24x16/config.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/24x16/event.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/24x16/mqtt.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/24x16/output24x16A.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/32x10/adc.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/32x10/binary_sensor.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/32x10/config.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/32x10/event.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/32x10/mqtt.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/32x10/output32x10A.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover/adc.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover/binary_sensor.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover/config.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover/cover.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover/event.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover/mqtt.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover/outputCover.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover_mix/adc.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover_mix/binary_sensor.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover_mix/config.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover_mix/cover.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover_mix/event.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover_mix/mqtt.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/cover_mix/outputCoverMix.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/adc.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/all_binary_sensor.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/binary_sensor.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/binary_sensor_v_0_7.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/config_24_16.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/event_all.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/event_v_0_7.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/led32x4A.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/output24x16A.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/output24x16A_v0.3.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/output32x10A.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/example_config/different_configs/output32x5A.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/exceptions.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/analog/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/analog/adc.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/display/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/display/fonts/danube__.ttf +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/gpio/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/gpio/expanders/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/gpio/expanders/mcp23017.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/gpio/expanders/pca9685.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/gpio/expanders/pcf8575.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/gpio/input/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/gpio/input/base.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/gpio/input/manager.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/i2c/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/i2c/bus.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/i2c/ina219.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/i2c/ina219_driver.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/i2c/mcp9808.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/i2c/pct2075.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/onewire/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/onewire/bus.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/onewire/dallas.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/onewire/ds2482.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/sensor/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/sensor/temperature/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/sensor/temperature/base.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/sensor/temperature/mcp9808.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/hardware/sensor/temperature/pct2075.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/integration/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/integration/homeassistant.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/integration/interlock.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/cli.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/client.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/coordinator.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/energy_meters/le-03mw.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/energy_meters/le-03mwct.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/energy_meters/orno-or-we-517.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/energy_meters/sdm120.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/energy_meters/sdm630.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/energy_meters/socomec_e03.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/energy_meters/socomec_e23.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/hvac/fujitsu-ac.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/hvac/ventclear.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/inverters/sofar.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/inverters/thessla.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/other/n4dsc08.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/other/r4dcb08.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/other/wanas415.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/sensors/boneio-edge-temp.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/sensors/cwt.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/sensors/dts1964_3f.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/sensors/dyp-a12-ultrasonic.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/sensors/gdfs.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/sensors/gdfx.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/sensors/liquid-sensor.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/sensors/pt100.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/sensors/sht20.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/devices/sensors/sht30.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/base.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/derived/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/derived/numeric.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/derived/select.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/derived/switch.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/derived/text.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/sensor/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/sensor/binary.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/sensor/numeric.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/sensor/text.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/writeable/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/writeable/binary.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/entities/writeable/numeric.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/modbus/utils.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/models/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/models/actions.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/models/events.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/models/files.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/models/logs.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/models/mqtt.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/models/state.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/runner.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/schema/actions_sensor.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/schema/actions_switch.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/schema/filters.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/schema/filters_adc.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/schema/id.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/schema/remote_devices.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/schema/schema.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/schema/temp_unit.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/schema/update_interval.yaml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/app.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/abap-CRCWOmpq.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/apex-DnsZk_dE.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/azcli-1IWB1ccx.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/bat-DPkNLes8.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/bicep-Corcdgou.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/cameligo-CGrWLZr3.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/clojure-D9WOWImG.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/codicon-DCmgc-ay.ttf +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/coffee-B7EJu28W.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/cpp-SEyurbux.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/csharp-BoL64M5l.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/csp-C46ZqvIl.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/css-DQU6DXDx.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/cypher-D84EuPTj.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/dart-D8lhlL1r.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/dockerfile-DLk6rpji.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/ecl-BO6FnfXk.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/editor.worker-B4pQIWZD.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/elixir-BRjLKONM.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/flow9-Cac8vKd7.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/fsharp-fd1GTHhf.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/go-O9LJTZXk.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/graphql-LQdxqEYJ.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/hcl-DxDQ3s82.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/index-BkP1mrhT.css +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/ini-BvajGCUy.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/java-SYsfObOQ.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/json.worker-aFakAbRR.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/julia-DQXNmw_w.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/kotlin-qQ0MG-9I.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/less-GGFNNJHn.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/lexon-Canl7DCW.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/lua-D28Ae8-K.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/m3-DPitgjJI.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/markdown-B811l8j2.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/mips-CdjsipkG.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/msdax-CYqgjx_P.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/mysql-BHd6q0vd.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/objective-c-B1aVtJYH.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/pascal-BhNW15KB.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/pascaligo-5jv8CcQD.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/perl-DlYyT36c.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/pgsql-Dy0bjov7.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/php-120yhfDK.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/pla-CjnFlu4u.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/postiats-CQpG440k.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/powerquery-DdJtto1Z.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/powershell-Bu_VLpJB.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/protobuf-IBS6jZEB.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/pug-kFxLfcjb.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/qsharp-q7JyzKFN.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/r-BIFz-_sK.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/redis-CHOsPHWR.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/redshift-CBifECDb.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/restructuredtext-CghPJEOS.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/ruby-CYWGW-b1.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/rust-DMDD0SHb.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/sb-BYAiYHFx.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/scala-Bqvq8jcR.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/scheme-Dhb-2j9p.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/scss-CTwUZ5N7.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/shell-CsDZo4DB.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/solidity-CME5AdoB.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/sophia-RYC1BQQz.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/sparql-KEyrF7De.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/sql-BdTr02Mf.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/st-C7iG7M4S.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/swift-D7IUmUK8.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/systemverilog-DgMryOEJ.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/tcl-PloMZuKG.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/twig-BfRIq3la.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/typespec-CzxlYoT_.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/vb-BwAE3J76.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/wgsl-B_1kOXbF.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/workbox-window.prod.es5-BIl4cyR9.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/assets/yaml.worker-DBeHcBRc.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/boneio-192.png +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/boneio-512.png +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/boneio.svg +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/boneio_fav.svg +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/adc.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/areas.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/boneio.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/cover.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/dallas.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/ds2482.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/ina219.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/lm75.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/logger.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/mcp23017.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/mcp9808.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/modbus.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/modbus_devices.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/mqtt.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/oled.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/output.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/output_group.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/pca9685.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/pcf8575.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/remote_devices.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/sensor.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/template.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/virtual_energy_sensor.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/schema/web.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/frontend-dist/workbox-226dbdbf.js +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/middleware/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/middleware/auth.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/auth.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/caddy.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/config.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/covers.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/modbus.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/outputs.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/remote_devices.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/sensors.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/system.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/templates.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/tools.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/routes/update.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/adc.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/areas.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/boneio.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/cover.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/dallas.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/ds2482.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/ina219.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/lm75.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/logger.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/mcp23017.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/mcp9808.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/modbus.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/modbus_devices.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/mqtt.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/oled.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/output.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/output_group.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/pca9685.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/pcf8575.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/remote_devices.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/sensor.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/template.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/virtual_energy_sensor.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/schema/web.schema.json +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/services/__init__.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/services/logs.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/web_server.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio/webui/websocket_manager.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio.egg-info/dependency_links.txt +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio.egg-info/entry_points.txt +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio.egg-info/requires.txt +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/boneio.egg-info/top_level.txt +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/pyproject.toml +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/setup.cfg +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/setup.py +0 -0
- {boneio-1.2.0.dev21 → boneio-1.2.0.dev23}/tests/test_py313_compatibility.py +0 -0
|
@@ -16,11 +16,11 @@ from boneio.const import (
|
|
|
16
16
|
OPEN,
|
|
17
17
|
OPENING,
|
|
18
18
|
)
|
|
19
|
-
from boneio.core.events import EventBus
|
|
19
|
+
from boneio.core.events import EventBus
|
|
20
20
|
from boneio.core.messaging import BasicMqtt
|
|
21
21
|
from boneio.core.utils import TimePeriod
|
|
22
22
|
from boneio.models import CoverState, PositionDict
|
|
23
|
-
from boneio.components.output import
|
|
23
|
+
from boneio.components.output import BasicOutput
|
|
24
24
|
from boneio.models.events import CoverEvent
|
|
25
25
|
|
|
26
26
|
_LOGGER = logging.getLogger(__name__)
|
|
@@ -30,8 +30,8 @@ class BaseCoverABC(ABC):
|
|
|
30
30
|
|
|
31
31
|
@abstractmethod
|
|
32
32
|
def __init__(self, id: str,
|
|
33
|
-
open_relay:
|
|
34
|
-
close_relay:
|
|
33
|
+
open_relay: BasicOutput,
|
|
34
|
+
close_relay: BasicOutput,
|
|
35
35
|
state_save: Callable,
|
|
36
36
|
open_time: TimePeriod,
|
|
37
37
|
close_time: TimePeriod,
|
|
@@ -147,8 +147,8 @@ class BaseVenetianCoverABC:
|
|
|
147
147
|
|
|
148
148
|
class BaseCover(BaseCoverABC, BasicMqtt):
|
|
149
149
|
def __init__(self, id: str,
|
|
150
|
-
open_relay:
|
|
151
|
-
close_relay:
|
|
150
|
+
open_relay: BasicOutput,
|
|
151
|
+
close_relay: BasicOutput,
|
|
152
152
|
state_save: Callable,
|
|
153
153
|
open_time: TimePeriod,
|
|
154
154
|
close_time: TimePeriod,
|
|
@@ -284,6 +284,29 @@ class BaseCover(BaseCoverABC, BasicMqtt):
|
|
|
284
284
|
else:
|
|
285
285
|
await self.close()
|
|
286
286
|
|
|
287
|
+
async def smart_toggle(self, always_open_till: int = 50) -> None:
|
|
288
|
+
"""Smart toggle with position threshold.
|
|
289
|
+
|
|
290
|
+
If cover is moving → stop.
|
|
291
|
+
If position <= always_open_till → open (to 100%).
|
|
292
|
+
If position > always_open_till → normal toggle (based on last_operation).
|
|
293
|
+
|
|
294
|
+
Args:
|
|
295
|
+
always_open_till: Position threshold (0-100%). Below or equal this
|
|
296
|
+
value the cover will always open. Above it, normal toggle applies.
|
|
297
|
+
"""
|
|
298
|
+
_LOGGER.debug(
|
|
299
|
+
"Smart toggle cover %s (position=%d%%, threshold=%d%%)",
|
|
300
|
+
self._id, self._position, always_open_till,
|
|
301
|
+
)
|
|
302
|
+
if self._current_operation != IDLE:
|
|
303
|
+
await self.stop()
|
|
304
|
+
elif self._position <= always_open_till:
|
|
305
|
+
await self.open()
|
|
306
|
+
elif self._last_operation == CLOSING:
|
|
307
|
+
await self.open()
|
|
308
|
+
else:
|
|
309
|
+
await self.close()
|
|
287
310
|
|
|
288
311
|
@property
|
|
289
312
|
def state(self) -> str:
|
|
@@ -10,7 +10,7 @@ from boneio.const import CLOSE, CLOSING, IDLE, OPEN, OPENING, STOP
|
|
|
10
10
|
from boneio.components.cover.cover import BaseCover
|
|
11
11
|
from boneio.core.events import EventBus
|
|
12
12
|
from boneio.core.utils import TimePeriod
|
|
13
|
-
from boneio.components.output import
|
|
13
|
+
from boneio.components.output import BasicOutput
|
|
14
14
|
|
|
15
15
|
_LOGGER = logging.getLogger(__name__)
|
|
16
16
|
DEFAULT_RESTORED_STATE = {"position": 100}
|
|
@@ -19,8 +19,8 @@ class TimeBasedCover(BaseCover):
|
|
|
19
19
|
"""Time-based cover algorithm similar to ESPHome."""
|
|
20
20
|
def __init__(
|
|
21
21
|
self,
|
|
22
|
-
open_relay:
|
|
23
|
-
close_relay:
|
|
22
|
+
open_relay: BasicOutput,
|
|
23
|
+
close_relay: BasicOutput,
|
|
24
24
|
state_save: Callable,
|
|
25
25
|
open_time: TimePeriod,
|
|
26
26
|
close_time: TimePeriod,
|
|
@@ -72,6 +72,28 @@ class CoverManager:
|
|
|
72
72
|
config = self._manager._config_helper.reload_config()
|
|
73
73
|
self._config_covers = config.get(COVER, [])
|
|
74
74
|
self._manager._config_helper.clear_autodiscovery_type(ha_type=COVER)
|
|
75
|
+
|
|
76
|
+
# Remove covers that are no longer in config
|
|
77
|
+
new_ids = set()
|
|
78
|
+
for _cfg in self._config_covers:
|
|
79
|
+
if _cfg.get(ID):
|
|
80
|
+
new_ids.add(strip_accents(_cfg[ID]))
|
|
81
|
+
else:
|
|
82
|
+
_open = str(_cfg.get("open_relay", ""))
|
|
83
|
+
_close = str(_cfg.get("close_relay", ""))
|
|
84
|
+
new_ids.add(f"cover_{_open}_{_close}".lower().replace(" ", "_"))
|
|
85
|
+
|
|
86
|
+
removed_ids = [cid for cid in self._covers if cid not in new_ids]
|
|
87
|
+
for cid in removed_ids:
|
|
88
|
+
_LOGGER.info("Cover %s removed from config, cleaning up", cid)
|
|
89
|
+
cover = self._covers.pop(cid)
|
|
90
|
+
# Stop cover movement if running
|
|
91
|
+
try:
|
|
92
|
+
asyncio.ensure_future(cover.stop())
|
|
93
|
+
except Exception:
|
|
94
|
+
pass
|
|
95
|
+
# Remove HA autodiscovery
|
|
96
|
+
self._remove_cover_ha_discovery(cid)
|
|
75
97
|
|
|
76
98
|
for _config in self._config_covers:
|
|
77
99
|
# Get relay outputs for cover
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import asyncio
|
|
4
4
|
import logging
|
|
5
|
+
import subprocess
|
|
5
6
|
from itertools import cycle
|
|
6
7
|
from typing import TYPE_CHECKING
|
|
7
8
|
|
|
@@ -13,7 +14,7 @@ from luma.oled.device import sh1106
|
|
|
13
14
|
from PIL import Image, ImageDraw
|
|
14
15
|
from PIL.ImageDraw import ImageDraw as ImageDrawType
|
|
15
16
|
|
|
16
|
-
from boneio.const import OLED_PIN, UPTIME, WHITE
|
|
17
|
+
from boneio.const import LONG, OLED_PIN, SINGLE, UPTIME, WHITE
|
|
17
18
|
from boneio.core.events import EventBus, async_track_point_in_time, utcnow
|
|
18
19
|
from boneio.core.system import HostData
|
|
19
20
|
from boneio.core.utils.font_util import make_font
|
|
@@ -102,6 +103,24 @@ class Oled:
|
|
|
102
103
|
self._cancel_sleep_handle = None
|
|
103
104
|
self._sleep_timeout = sleep_timeout
|
|
104
105
|
|
|
106
|
+
# Shutdown confirmation state machine
|
|
107
|
+
# States: None -> "wait_release" -> "confirm" -> "progress" -> shutdown
|
|
108
|
+
# - First long press → show confirm screen, enter "wait_release"
|
|
109
|
+
# - Release after first long → enter "confirm" (waiting for second long)
|
|
110
|
+
# - Second long press → enter "progress" with filling progress bar
|
|
111
|
+
# - Hold 5s → execute shutdown
|
|
112
|
+
# - Single click or 10s timeout → cancel
|
|
113
|
+
self._shutdown_state: str | None = None
|
|
114
|
+
self._shutdown_cancel_handle = None
|
|
115
|
+
# Timer to detect button release (no LONG event for 300ms = released)
|
|
116
|
+
self._shutdown_release_timer: asyncio.TimerHandle | None = None
|
|
117
|
+
# Last seen long press duration — used to detect new press cycle (duration resets)
|
|
118
|
+
self._shutdown_last_long_duration: float = 0.0
|
|
119
|
+
# Duration (seconds) the user must hold the button to confirm shutdown
|
|
120
|
+
self._shutdown_hold_duration: float = 5.0
|
|
121
|
+
# Timeout (seconds) to cancel shutdown confirmation if no action
|
|
122
|
+
self._shutdown_confirm_timeout: float = 10.0
|
|
123
|
+
|
|
105
124
|
# Initialize I2C display
|
|
106
125
|
try:
|
|
107
126
|
# Use luma.oled for now, but could be refactored to use SMBus2I2C
|
|
@@ -219,14 +238,98 @@ class Oled:
|
|
|
219
238
|
# Display the centered QR code
|
|
220
239
|
self._device.display(display_image)
|
|
221
240
|
|
|
222
|
-
async def _handle_button_press(self, event
|
|
223
|
-
"""Handle button press event from input.
|
|
224
|
-
|
|
241
|
+
async def _handle_button_press(self, event) -> None:
|
|
242
|
+
"""Handle button press event from input.
|
|
243
|
+
|
|
244
|
+
Supports shutdown flow via long press:
|
|
245
|
+
1. First long press → show confirmation screen
|
|
246
|
+
2. User releases button → state moves to "confirm"
|
|
247
|
+
3. Second long press (held 5s) → progress bar fills, then shutdown
|
|
248
|
+
4. Any single click or 10s timeout → cancel shutdown
|
|
249
|
+
|
|
250
|
+
The detector emits periodic LONG events (every 200ms) with growing
|
|
251
|
+
duration while the button is held. A new press cycle is detected
|
|
252
|
+
when duration resets (new duration < last tracked duration).
|
|
253
|
+
|
|
254
|
+
Args:
|
|
255
|
+
event: InputEvent from EventBus with click_type and duration
|
|
256
|
+
"""
|
|
257
|
+
click_type = getattr(event, "click_type", None)
|
|
258
|
+
duration = getattr(event, "duration", None) or 0.0
|
|
259
|
+
|
|
260
|
+
_LOGGER.debug("OLED button event: click_type=%s, duration=%.2f, shutdown_state=%s",
|
|
261
|
+
click_type, duration, self._shutdown_state)
|
|
262
|
+
|
|
263
|
+
# --- Shutdown state machine ---
|
|
264
|
+
|
|
265
|
+
if self._shutdown_state == "wait_release":
|
|
266
|
+
# Absorb periodic LONG events from the first long press.
|
|
267
|
+
# Detector does NOT emit SINGLE after long press release.
|
|
268
|
+
# Detect release via timer: each LONG resets a 300ms timer.
|
|
269
|
+
# When no more LONG events arrive, timer fires → "confirm".
|
|
270
|
+
if click_type == LONG:
|
|
271
|
+
self._shutdown_last_long_duration = duration
|
|
272
|
+
# Reset release-detection timer
|
|
273
|
+
self._reset_release_timer()
|
|
274
|
+
return
|
|
275
|
+
elif click_type == SINGLE:
|
|
276
|
+
# Shouldn't happen after long, but handle gracefully
|
|
277
|
+
self._cancel_release_timer()
|
|
278
|
+
self._shutdown_state = "confirm"
|
|
279
|
+
self._shutdown_last_long_duration = 0.0
|
|
280
|
+
return
|
|
281
|
+
# Ignore other events
|
|
282
|
+
return
|
|
283
|
+
|
|
284
|
+
if self._shutdown_state == "confirm":
|
|
285
|
+
if click_type == LONG:
|
|
286
|
+
# Second long press — enter progress mode
|
|
287
|
+
self._shutdown_state = "progress"
|
|
288
|
+
self._cancel_shutdown_timeout()
|
|
289
|
+
self._shutdown_last_long_duration = duration
|
|
290
|
+
self._draw_shutdown_progress(duration)
|
|
291
|
+
if duration >= self._shutdown_hold_duration:
|
|
292
|
+
await self._execute_shutdown()
|
|
293
|
+
return
|
|
294
|
+
elif click_type == SINGLE:
|
|
295
|
+
# Single click cancels shutdown confirmation
|
|
296
|
+
self._cancel_shutdown()
|
|
297
|
+
return
|
|
298
|
+
# Ignore other events during confirm
|
|
299
|
+
return
|
|
300
|
+
|
|
301
|
+
if self._shutdown_state == "progress":
|
|
302
|
+
if click_type == LONG:
|
|
303
|
+
if duration < self._shutdown_last_long_duration:
|
|
304
|
+
# Duration reset — user released and pressed again, cancel
|
|
305
|
+
self._cancel_shutdown()
|
|
306
|
+
return
|
|
307
|
+
# Still holding — update progress bar
|
|
308
|
+
self._shutdown_last_long_duration = duration
|
|
309
|
+
self._draw_shutdown_progress(duration)
|
|
310
|
+
if duration >= self._shutdown_hold_duration:
|
|
311
|
+
await self._execute_shutdown()
|
|
312
|
+
return
|
|
313
|
+
else:
|
|
314
|
+
# Released (single) or other — cancel
|
|
315
|
+
self._cancel_shutdown()
|
|
316
|
+
return
|
|
317
|
+
|
|
318
|
+
# --- Normal mode ---
|
|
225
319
|
if self._sleep:
|
|
226
|
-
# Display is sleeping - wake it up
|
|
227
320
|
self.wake_up()
|
|
228
|
-
|
|
229
|
-
|
|
321
|
+
return
|
|
322
|
+
|
|
323
|
+
if click_type == LONG and duration < 1.0:
|
|
324
|
+
# First long press event — show confirmation, enter wait_release
|
|
325
|
+
self._shutdown_state = "wait_release"
|
|
326
|
+
self._shutdown_last_long_duration = duration
|
|
327
|
+
self._draw_shutdown_confirm()
|
|
328
|
+
self._start_shutdown_timeout()
|
|
329
|
+
self._reset_release_timer()
|
|
330
|
+
return
|
|
331
|
+
|
|
332
|
+
if click_type == SINGLE:
|
|
230
333
|
self._next_screen()
|
|
231
334
|
|
|
232
335
|
def _next_screen(self) -> None:
|
|
@@ -240,6 +343,150 @@ class Oled:
|
|
|
240
343
|
self._current_screen = next(self._screen_cycle)
|
|
241
344
|
self.render_display()
|
|
242
345
|
|
|
346
|
+
# --- Shutdown helper methods ---
|
|
347
|
+
|
|
348
|
+
def _draw_shutdown_confirm(self) -> None:
|
|
349
|
+
"""Draw shutdown confirmation screen on OLED.
|
|
350
|
+
|
|
351
|
+
Shows a warning message asking the user to hold the button
|
|
352
|
+
for 5 seconds to confirm system shutdown.
|
|
353
|
+
"""
|
|
354
|
+
with canvas(self._device) as draw:
|
|
355
|
+
# Warning triangle
|
|
356
|
+
draw.polygon([(64, 2), (54, 18), (74, 18)], outline=WHITE)
|
|
357
|
+
draw.text((61, 5), "!", font=fonts["small"], fill=WHITE)
|
|
358
|
+
# Message
|
|
359
|
+
draw.text((10, 24), "Shutdown system?", font=fonts["small"], fill=WHITE)
|
|
360
|
+
draw.text((4, 38), "Hold button 5s to confirm", font=fonts["extraSmall"], fill=WHITE)
|
|
361
|
+
draw.text((8, 52), "Click to cancel (10s)", font=fonts["extraSmall"], fill=WHITE)
|
|
362
|
+
|
|
363
|
+
def _draw_shutdown_progress(self, duration: float) -> None:
|
|
364
|
+
"""Draw shutdown progress bar on OLED.
|
|
365
|
+
|
|
366
|
+
Shows a progress bar that fills proportionally to how long
|
|
367
|
+
the user has been holding the button vs the required duration.
|
|
368
|
+
|
|
369
|
+
Args:
|
|
370
|
+
duration: How long the button has been held (seconds)
|
|
371
|
+
"""
|
|
372
|
+
progress = min(duration / self._shutdown_hold_duration, 1.0)
|
|
373
|
+
bar_x, bar_y = 10, 34
|
|
374
|
+
bar_w, bar_h = 108, 14
|
|
375
|
+
fill_w = int(bar_w * progress)
|
|
376
|
+
|
|
377
|
+
with canvas(self._device) as draw:
|
|
378
|
+
draw.text((20, 4), "Shutting down...", font=fonts["small"], fill=WHITE)
|
|
379
|
+
draw.text((28, 18), f"{int(progress * 100)}%", font=fonts["small"], fill=WHITE)
|
|
380
|
+
# Progress bar outline
|
|
381
|
+
draw.rectangle([bar_x, bar_y, bar_x + bar_w, bar_y + bar_h], outline=WHITE)
|
|
382
|
+
# Progress bar fill
|
|
383
|
+
if fill_w > 0:
|
|
384
|
+
draw.rectangle([bar_x + 1, bar_y + 1, bar_x + fill_w - 1, bar_y + bar_h - 1], fill=WHITE)
|
|
385
|
+
draw.text((22, 54), "Release to cancel", font=fonts["extraSmall"], fill=WHITE)
|
|
386
|
+
|
|
387
|
+
def _start_shutdown_timeout(self) -> None:
|
|
388
|
+
"""Start a 10-second timeout that cancels the shutdown confirmation.
|
|
389
|
+
|
|
390
|
+
If the user doesn't interact within the timeout period,
|
|
391
|
+
the shutdown flow is cancelled and the normal screen is restored.
|
|
392
|
+
"""
|
|
393
|
+
self._cancel_shutdown_timeout()
|
|
394
|
+
loop = self._event_bus._loop
|
|
395
|
+
|
|
396
|
+
def _timeout_callback() -> None:
|
|
397
|
+
"""Cancel shutdown after timeout expires."""
|
|
398
|
+
_LOGGER.info("Shutdown confirmation timed out, cancelling")
|
|
399
|
+
self._shutdown_state = None
|
|
400
|
+
self._shutdown_cancel_handle = None
|
|
401
|
+
self.render_display()
|
|
402
|
+
|
|
403
|
+
self._shutdown_cancel_handle = loop.call_later(
|
|
404
|
+
self._shutdown_confirm_timeout, _timeout_callback
|
|
405
|
+
)
|
|
406
|
+
|
|
407
|
+
def _cancel_shutdown_timeout(self) -> None:
|
|
408
|
+
"""Cancel the pending shutdown timeout timer."""
|
|
409
|
+
if self._shutdown_cancel_handle is not None:
|
|
410
|
+
self._shutdown_cancel_handle.cancel()
|
|
411
|
+
self._shutdown_cancel_handle = None
|
|
412
|
+
|
|
413
|
+
def _reset_release_timer(self) -> None:
|
|
414
|
+
"""Reset the 300ms release-detection timer.
|
|
415
|
+
|
|
416
|
+
Called on each periodic LONG event during wait_release state.
|
|
417
|
+
If no more LONG events arrive within 300ms, the timer fires
|
|
418
|
+
and transitions to 'confirm' state (button was released).
|
|
419
|
+
"""
|
|
420
|
+
self._cancel_release_timer()
|
|
421
|
+
loop = self._event_bus._loop
|
|
422
|
+
|
|
423
|
+
def _on_release_detected() -> None:
|
|
424
|
+
"""No LONG event for 300ms — button was released."""
|
|
425
|
+
self._shutdown_release_timer = None
|
|
426
|
+
if self._shutdown_state == "wait_release":
|
|
427
|
+
_LOGGER.debug("OLED button release detected (no LONG for 300ms)")
|
|
428
|
+
self._shutdown_state = "confirm"
|
|
429
|
+
self._shutdown_last_long_duration = 0.0
|
|
430
|
+
# Timeout already running from first long press
|
|
431
|
+
|
|
432
|
+
self._shutdown_release_timer = loop.call_later(0.3, _on_release_detected)
|
|
433
|
+
|
|
434
|
+
def _cancel_release_timer(self) -> None:
|
|
435
|
+
"""Cancel the pending release-detection timer."""
|
|
436
|
+
if self._shutdown_release_timer is not None:
|
|
437
|
+
self._shutdown_release_timer.cancel()
|
|
438
|
+
self._shutdown_release_timer = None
|
|
439
|
+
|
|
440
|
+
def _cancel_shutdown(self) -> None:
|
|
441
|
+
"""Cancel the shutdown flow and return to normal display.
|
|
442
|
+
|
|
443
|
+
Resets the shutdown state machine and restores the current screen.
|
|
444
|
+
"""
|
|
445
|
+
_LOGGER.info("Shutdown cancelled by user")
|
|
446
|
+
self._cancel_shutdown_timeout()
|
|
447
|
+
self._cancel_release_timer()
|
|
448
|
+
self._shutdown_state = None
|
|
449
|
+
self._shutdown_last_long_duration = 0.0
|
|
450
|
+
self.render_display()
|
|
451
|
+
|
|
452
|
+
async def _execute_shutdown(self) -> None:
|
|
453
|
+
"""Execute system shutdown.
|
|
454
|
+
|
|
455
|
+
Draws a final 'Goodbye' message on the OLED, then runs
|
|
456
|
+
'sudo shutdown -h now' to power off the device.
|
|
457
|
+
"""
|
|
458
|
+
_LOGGER.warning("System shutdown initiated from OLED button")
|
|
459
|
+
self._shutdown_state = None
|
|
460
|
+
self._shutdown_last_long_duration = 0.0
|
|
461
|
+
self._cancel_shutdown_timeout()
|
|
462
|
+
|
|
463
|
+
# Draw goodbye screen
|
|
464
|
+
with canvas(self._device) as draw:
|
|
465
|
+
draw.text((20, 10), "Goodbye!", font=fonts["big"], fill=WHITE)
|
|
466
|
+
draw.text((15, 35), "System shutting down...", font=fonts["extraSmall"], fill=WHITE)
|
|
467
|
+
|
|
468
|
+
# Small delay so the user sees the message
|
|
469
|
+
await asyncio.sleep(1)
|
|
470
|
+
|
|
471
|
+
try:
|
|
472
|
+
subprocess.run(
|
|
473
|
+
["sudo", "shutdown", "-h", "now"],
|
|
474
|
+
check=True,
|
|
475
|
+
capture_output=True,
|
|
476
|
+
text=True,
|
|
477
|
+
)
|
|
478
|
+
except subprocess.CalledProcessError as e:
|
|
479
|
+
_LOGGER.error("Failed to shutdown device: %s", e.stderr)
|
|
480
|
+
# Show error on OLED and return to normal
|
|
481
|
+
with canvas(self._device) as draw:
|
|
482
|
+
draw.text((10, 20), "Shutdown failed!", font=fonts["small"], fill=WHITE)
|
|
483
|
+
draw.text((10, 40), str(e.stderr)[:20], font=fonts["extraSmall"], fill=WHITE)
|
|
484
|
+
await asyncio.sleep(3)
|
|
485
|
+
self.render_display()
|
|
486
|
+
except Exception as e:
|
|
487
|
+
_LOGGER.error("Error shutting down device: %s", e)
|
|
488
|
+
self.render_display()
|
|
489
|
+
|
|
243
490
|
def render_display(self) -> None:
|
|
244
491
|
"""Render display - main method that decides what to display."""
|
|
245
492
|
|
|
@@ -35,7 +35,7 @@ schema:
|
|
|
35
35
|
action: ['cover', 'cover_over_mqtt', 'remote_cover']
|
|
36
36
|
forbidden_if:
|
|
37
37
|
action: ['output', 'mqtt', 'mqtt_output', 'remote_output']
|
|
38
|
-
allowed: ['TOGGLE', 'OPEN', 'CLOSE', 'STOP', 'TOGGLE_OPEN', 'TOGGLE_CLOSE', 'TILT', 'TILT_OPEN', 'TILT_CLOSE']
|
|
38
|
+
allowed: ['TOGGLE', 'OPEN', 'CLOSE', 'STOP', 'TOGGLE_OPEN', 'TOGGLE_CLOSE', 'SMART_TOGGLE', 'TILT', 'TILT_OPEN', 'TILT_CLOSE']
|
|
39
39
|
coerce: action_field
|
|
40
40
|
default: TOGGLE
|
|
41
41
|
case_insensitive: true
|
|
@@ -58,6 +58,18 @@ schema:
|
|
|
58
58
|
required: False
|
|
59
59
|
meta:
|
|
60
60
|
label: Tilt position to set cover to. 0 means closed, 100 means opened.
|
|
61
|
+
always_open_till:
|
|
62
|
+
type: integer
|
|
63
|
+
required: False
|
|
64
|
+
min: 0
|
|
65
|
+
max: 100
|
|
66
|
+
default: 50
|
|
67
|
+
meta:
|
|
68
|
+
label: Smart toggle threshold (0-100%).
|
|
69
|
+
description: |
|
|
70
|
+
Position threshold for SMART_TOGGLE action.
|
|
71
|
+
If cover position is at or below this value, it will always open.
|
|
72
|
+
Above this value, normal toggle behavior applies.
|
|
61
73
|
action_output:
|
|
62
74
|
type: string
|
|
63
75
|
required_if:
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{m as et}from"./index-B6BS4-3O.js";var tt=Object.defineProperty,rt=Object.getOwnPropertyDescriptor,nt=Object.getOwnPropertyNames,it=Object.prototype.hasOwnProperty,ot=(e,n,i,r)=>{if(n&&typeof n=="object"||typeof n=="function")for(let t of nt(n))!it.call(e,t)&&t!==i&&tt(e,t,{get:()=>n[t],enumerable:!(r=rt(n,t))||r.enumerable});return e},at=(e,n,i)=>(ot(e,n,"default"),i),d={};at(d,et);var st=120*1e3,ut=class{constructor(e){this._defaults=e,this._worker=null,this._client=null,this._idleCheckInterval=window.setInterval(()=>this._checkIfIdle(),30*1e3),this._lastUsedTime=0,this._configChangeListener=this._defaults.onDidChange(()=>this._stopWorker())}_stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}dispose(){clearInterval(this._idleCheckInterval),this._configChangeListener.dispose(),this._stopWorker()}_checkIfIdle(){if(!this._worker)return;Date.now()-this._lastUsedTime>st&&this._stopWorker()}_getClient(){return this._lastUsedTime=Date.now(),this._client||(this._worker=d.editor.createWebWorker({moduleId:"vs/language/css/cssWorker",label:this._defaults.languageId,createData:{options:this._defaults.options,languageId:this._defaults.languageId}}),this._client=this._worker.getProxy()),this._client}getLanguageServiceWorker(...e){let n;return this._getClient().then(i=>{n=i}).then(i=>{if(this._worker)return this._worker.withSyncedResources(e)}).then(i=>n)}},T;(function(e){function n(i){return typeof i=="string"}e.is=n})(T||(T={}));var O;(function(e){function n(i){return typeof i=="string"}e.is=n})(O||(O={}));var Y;(function(e){e.MIN_VALUE=-2147483648,e.MAX_VALUE=2147483647;function n(i){return typeof i=="number"&&e.MIN_VALUE<=i&&i<=e.MAX_VALUE}e.is=n})(Y||(Y={}));var M;(function(e){e.MIN_VALUE=0,e.MAX_VALUE=2147483647;function n(i){return typeof i=="number"&&e.MIN_VALUE<=i&&i<=e.MAX_VALUE}e.is=n})(M||(M={}));var w;(function(e){function n(r,t){return r===Number.MAX_VALUE&&(r=M.MAX_VALUE),t===Number.MAX_VALUE&&(t=M.MAX_VALUE),{line:r,character:t}}e.create=n;function i(r){let t=r;return a.objectLiteral(t)&&a.uinteger(t.line)&&a.uinteger(t.character)}e.is=i})(w||(w={}));var h;(function(e){function n(r,t,o,s){if(a.uinteger(r)&&a.uinteger(t)&&a.uinteger(o)&&a.uinteger(s))return{start:w.create(r,t),end:w.create(o,s)};if(w.is(r)&&w.is(t))return{start:r,end:t};throw new Error(`Range#create called with invalid arguments[${r}, ${t}, ${o}, ${s}]`)}e.create=n;function i(r){let t=r;return a.objectLiteral(t)&&w.is(t.start)&&w.is(t.end)}e.is=i})(h||(h={}));var C;(function(e){function n(r,t){return{uri:r,range:t}}e.create=n;function i(r){let t=r;return a.objectLiteral(t)&&h.is(t.range)&&(a.string(t.uri)||a.undefined(t.uri))}e.is=i})(C||(C={}));var Z;(function(e){function n(r,t,o,s){return{targetUri:r,targetRange:t,targetSelectionRange:o,originSelectionRange:s}}e.create=n;function i(r){let t=r;return a.objectLiteral(t)&&h.is(t.targetRange)&&a.string(t.targetUri)&&h.is(t.targetSelectionRange)&&(h.is(t.originSelectionRange)||a.undefined(t.originSelectionRange))}e.is=i})(Z||(Z={}));var S;(function(e){function n(r,t,o,s){return{red:r,green:t,blue:o,alpha:s}}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&a.numberRange(t.red,0,1)&&a.numberRange(t.green,0,1)&&a.numberRange(t.blue,0,1)&&a.numberRange(t.alpha,0,1)}e.is=i})(S||(S={}));var K;(function(e){function n(r,t){return{range:r,color:t}}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&h.is(t.range)&&S.is(t.color)}e.is=i})(K||(K={}));var ee;(function(e){function n(r,t,o){return{label:r,textEdit:t,additionalTextEdits:o}}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&a.string(t.label)&&(a.undefined(t.textEdit)||E.is(t))&&(a.undefined(t.additionalTextEdits)||a.typedArray(t.additionalTextEdits,E.is))}e.is=i})(ee||(ee={}));var A;(function(e){e.Comment="comment",e.Imports="imports",e.Region="region"})(A||(A={}));var te;(function(e){function n(r,t,o,s,u,f){const c={startLine:r,endLine:t};return a.defined(o)&&(c.startCharacter=o),a.defined(s)&&(c.endCharacter=s),a.defined(u)&&(c.kind=u),a.defined(f)&&(c.collapsedText=f),c}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&a.uinteger(t.startLine)&&a.uinteger(t.startLine)&&(a.undefined(t.startCharacter)||a.uinteger(t.startCharacter))&&(a.undefined(t.endCharacter)||a.uinteger(t.endCharacter))&&(a.undefined(t.kind)||a.string(t.kind))}e.is=i})(te||(te={}));var U;(function(e){function n(r,t){return{location:r,message:t}}e.create=n;function i(r){let t=r;return a.defined(t)&&C.is(t.location)&&a.string(t.message)}e.is=i})(U||(U={}));var x;(function(e){e.Error=1,e.Warning=2,e.Information=3,e.Hint=4})(x||(x={}));var re;(function(e){e.Unnecessary=1,e.Deprecated=2})(re||(re={}));var ne;(function(e){function n(i){const r=i;return a.objectLiteral(r)&&a.string(r.href)}e.is=n})(ne||(ne={}));var y;(function(e){function n(r,t,o,s,u,f){let c={range:r,message:t};return a.defined(o)&&(c.severity=o),a.defined(s)&&(c.code=s),a.defined(u)&&(c.source=u),a.defined(f)&&(c.relatedInformation=f),c}e.create=n;function i(r){var t;let o=r;return a.defined(o)&&h.is(o.range)&&a.string(o.message)&&(a.number(o.severity)||a.undefined(o.severity))&&(a.integer(o.code)||a.string(o.code)||a.undefined(o.code))&&(a.undefined(o.codeDescription)||a.string((t=o.codeDescription)===null||t===void 0?void 0:t.href))&&(a.string(o.source)||a.undefined(o.source))&&(a.undefined(o.relatedInformation)||a.typedArray(o.relatedInformation,U.is))}e.is=i})(y||(y={}));var I;(function(e){function n(r,t,...o){let s={title:r,command:t};return a.defined(o)&&o.length>0&&(s.arguments=o),s}e.create=n;function i(r){let t=r;return a.defined(t)&&a.string(t.title)&&a.string(t.command)}e.is=i})(I||(I={}));var E;(function(e){function n(o,s){return{range:o,newText:s}}e.replace=n;function i(o,s){return{range:{start:o,end:o},newText:s}}e.insert=i;function r(o){return{range:o,newText:""}}e.del=r;function t(o){const s=o;return a.objectLiteral(s)&&a.string(s.newText)&&h.is(s.range)}e.is=t})(E||(E={}));var V;(function(e){function n(r,t,o){const s={label:r};return t!==void 0&&(s.needsConfirmation=t),o!==void 0&&(s.description=o),s}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&a.string(t.label)&&(a.boolean(t.needsConfirmation)||t.needsConfirmation===void 0)&&(a.string(t.description)||t.description===void 0)}e.is=i})(V||(V={}));var L;(function(e){function n(i){const r=i;return a.string(r)}e.is=n})(L||(L={}));var ie;(function(e){function n(o,s,u){return{range:o,newText:s,annotationId:u}}e.replace=n;function i(o,s,u){return{range:{start:o,end:o},newText:s,annotationId:u}}e.insert=i;function r(o,s){return{range:o,newText:"",annotationId:s}}e.del=r;function t(o){const s=o;return E.is(s)&&(V.is(s.annotationId)||L.is(s.annotationId))}e.is=t})(ie||(ie={}));var W;(function(e){function n(r,t){return{textDocument:r,edits:t}}e.create=n;function i(r){let t=r;return a.defined(t)&&B.is(t.textDocument)&&Array.isArray(t.edits)}e.is=i})(W||(W={}));var H;(function(e){function n(r,t,o){let s={kind:"create",uri:r};return t!==void 0&&(t.overwrite!==void 0||t.ignoreIfExists!==void 0)&&(s.options=t),o!==void 0&&(s.annotationId=o),s}e.create=n;function i(r){let t=r;return t&&t.kind==="create"&&a.string(t.uri)&&(t.options===void 0||(t.options.overwrite===void 0||a.boolean(t.options.overwrite))&&(t.options.ignoreIfExists===void 0||a.boolean(t.options.ignoreIfExists)))&&(t.annotationId===void 0||L.is(t.annotationId))}e.is=i})(H||(H={}));var X;(function(e){function n(r,t,o,s){let u={kind:"rename",oldUri:r,newUri:t};return o!==void 0&&(o.overwrite!==void 0||o.ignoreIfExists!==void 0)&&(u.options=o),s!==void 0&&(u.annotationId=s),u}e.create=n;function i(r){let t=r;return t&&t.kind==="rename"&&a.string(t.oldUri)&&a.string(t.newUri)&&(t.options===void 0||(t.options.overwrite===void 0||a.boolean(t.options.overwrite))&&(t.options.ignoreIfExists===void 0||a.boolean(t.options.ignoreIfExists)))&&(t.annotationId===void 0||L.is(t.annotationId))}e.is=i})(X||(X={}));var $;(function(e){function n(r,t,o){let s={kind:"delete",uri:r};return t!==void 0&&(t.recursive!==void 0||t.ignoreIfNotExists!==void 0)&&(s.options=t),o!==void 0&&(s.annotationId=o),s}e.create=n;function i(r){let t=r;return t&&t.kind==="delete"&&a.string(t.uri)&&(t.options===void 0||(t.options.recursive===void 0||a.boolean(t.options.recursive))&&(t.options.ignoreIfNotExists===void 0||a.boolean(t.options.ignoreIfNotExists)))&&(t.annotationId===void 0||L.is(t.annotationId))}e.is=i})($||($={}));var z;(function(e){function n(i){let r=i;return r&&(r.changes!==void 0||r.documentChanges!==void 0)&&(r.documentChanges===void 0||r.documentChanges.every(t=>a.string(t.kind)?H.is(t)||X.is(t)||$.is(t):W.is(t)))}e.is=n})(z||(z={}));var oe;(function(e){function n(r){return{uri:r}}e.create=n;function i(r){let t=r;return a.defined(t)&&a.string(t.uri)}e.is=i})(oe||(oe={}));var ae;(function(e){function n(r,t){return{uri:r,version:t}}e.create=n;function i(r){let t=r;return a.defined(t)&&a.string(t.uri)&&a.integer(t.version)}e.is=i})(ae||(ae={}));var B;(function(e){function n(r,t){return{uri:r,version:t}}e.create=n;function i(r){let t=r;return a.defined(t)&&a.string(t.uri)&&(t.version===null||a.integer(t.version))}e.is=i})(B||(B={}));var se;(function(e){function n(r,t,o,s){return{uri:r,languageId:t,version:o,text:s}}e.create=n;function i(r){let t=r;return a.defined(t)&&a.string(t.uri)&&a.string(t.languageId)&&a.integer(t.version)&&a.string(t.text)}e.is=i})(se||(se={}));var q;(function(e){e.PlainText="plaintext",e.Markdown="markdown";function n(i){const r=i;return r===e.PlainText||r===e.Markdown}e.is=n})(q||(q={}));var P;(function(e){function n(i){const r=i;return a.objectLiteral(i)&&q.is(r.kind)&&a.string(r.value)}e.is=n})(P||(P={}));var v;(function(e){e.Text=1,e.Method=2,e.Function=3,e.Constructor=4,e.Field=5,e.Variable=6,e.Class=7,e.Interface=8,e.Module=9,e.Property=10,e.Unit=11,e.Value=12,e.Enum=13,e.Keyword=14,e.Snippet=15,e.Color=16,e.File=17,e.Reference=18,e.Folder=19,e.EnumMember=20,e.Constant=21,e.Struct=22,e.Event=23,e.Operator=24,e.TypeParameter=25})(v||(v={}));var Q;(function(e){e.PlainText=1,e.Snippet=2})(Q||(Q={}));var ue;(function(e){e.Deprecated=1})(ue||(ue={}));var ce;(function(e){function n(r,t,o){return{newText:r,insert:t,replace:o}}e.create=n;function i(r){const t=r;return t&&a.string(t.newText)&&h.is(t.insert)&&h.is(t.replace)}e.is=i})(ce||(ce={}));var de;(function(e){e.asIs=1,e.adjustIndentation=2})(de||(de={}));var le;(function(e){function n(i){const r=i;return r&&(a.string(r.detail)||r.detail===void 0)&&(a.string(r.description)||r.description===void 0)}e.is=n})(le||(le={}));var fe;(function(e){function n(i){return{label:i}}e.create=n})(fe||(fe={}));var ge;(function(e){function n(i,r){return{items:i||[],isIncomplete:!!r}}e.create=n})(ge||(ge={}));var F;(function(e){function n(r){return r.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}e.fromPlainText=n;function i(r){const t=r;return a.string(t)||a.objectLiteral(t)&&a.string(t.language)&&a.string(t.value)}e.is=i})(F||(F={}));var he;(function(e){function n(i){let r=i;return!!r&&a.objectLiteral(r)&&(P.is(r.contents)||F.is(r.contents)||a.typedArray(r.contents,F.is))&&(i.range===void 0||h.is(i.range))}e.is=n})(he||(he={}));var ve;(function(e){function n(i,r){return r?{label:i,documentation:r}:{label:i}}e.create=n})(ve||(ve={}));var pe;(function(e){function n(i,r,...t){let o={label:i};return a.defined(r)&&(o.documentation=r),a.defined(t)?o.parameters=t:o.parameters=[],o}e.create=n})(pe||(pe={}));var R;(function(e){e.Text=1,e.Read=2,e.Write=3})(R||(R={}));var me;(function(e){function n(i,r){let t={range:i};return a.number(r)&&(t.kind=r),t}e.create=n})(me||(me={}));var p;(function(e){e.File=1,e.Module=2,e.Namespace=3,e.Package=4,e.Class=5,e.Method=6,e.Property=7,e.Field=8,e.Constructor=9,e.Enum=10,e.Interface=11,e.Function=12,e.Variable=13,e.Constant=14,e.String=15,e.Number=16,e.Boolean=17,e.Array=18,e.Object=19,e.Key=20,e.Null=21,e.EnumMember=22,e.Struct=23,e.Event=24,e.Operator=25,e.TypeParameter=26})(p||(p={}));var _e;(function(e){e.Deprecated=1})(_e||(_e={}));var be;(function(e){function n(i,r,t,o,s){let u={name:i,kind:r,location:{uri:o,range:t}};return s&&(u.containerName=s),u}e.create=n})(be||(be={}));var we;(function(e){function n(i,r,t,o){return o!==void 0?{name:i,kind:r,location:{uri:t,range:o}}:{name:i,kind:r,location:{uri:t}}}e.create=n})(we||(we={}));var ke;(function(e){function n(r,t,o,s,u,f){let c={name:r,detail:t,kind:o,range:s,selectionRange:u};return f!==void 0&&(c.children=f),c}e.create=n;function i(r){let t=r;return t&&a.string(t.name)&&a.number(t.kind)&&h.is(t.range)&&h.is(t.selectionRange)&&(t.detail===void 0||a.string(t.detail))&&(t.deprecated===void 0||a.boolean(t.deprecated))&&(t.children===void 0||Array.isArray(t.children))&&(t.tags===void 0||Array.isArray(t.tags))}e.is=i})(ke||(ke={}));var xe;(function(e){e.Empty="",e.QuickFix="quickfix",e.Refactor="refactor",e.RefactorExtract="refactor.extract",e.RefactorInline="refactor.inline",e.RefactorRewrite="refactor.rewrite",e.Source="source",e.SourceOrganizeImports="source.organizeImports",e.SourceFixAll="source.fixAll"})(xe||(xe={}));var j;(function(e){e.Invoked=1,e.Automatic=2})(j||(j={}));var Ie;(function(e){function n(r,t,o){let s={diagnostics:r};return t!=null&&(s.only=t),o!=null&&(s.triggerKind=o),s}e.create=n;function i(r){let t=r;return a.defined(t)&&a.typedArray(t.diagnostics,y.is)&&(t.only===void 0||a.typedArray(t.only,a.string))&&(t.triggerKind===void 0||t.triggerKind===j.Invoked||t.triggerKind===j.Automatic)}e.is=i})(Ie||(Ie={}));var Ee;(function(e){function n(r,t,o){let s={title:r},u=!0;return typeof t=="string"?(u=!1,s.kind=t):I.is(t)?s.command=t:s.edit=t,u&&o!==void 0&&(s.kind=o),s}e.create=n;function i(r){let t=r;return t&&a.string(t.title)&&(t.diagnostics===void 0||a.typedArray(t.diagnostics,y.is))&&(t.kind===void 0||a.string(t.kind))&&(t.edit!==void 0||t.command!==void 0)&&(t.command===void 0||I.is(t.command))&&(t.isPreferred===void 0||a.boolean(t.isPreferred))&&(t.edit===void 0||z.is(t.edit))}e.is=i})(Ee||(Ee={}));var Le;(function(e){function n(r,t){let o={range:r};return a.defined(t)&&(o.data=t),o}e.create=n;function i(r){let t=r;return a.defined(t)&&h.is(t.range)&&(a.undefined(t.command)||I.is(t.command))}e.is=i})(Le||(Le={}));var Ae;(function(e){function n(r,t){return{tabSize:r,insertSpaces:t}}e.create=n;function i(r){let t=r;return a.defined(t)&&a.uinteger(t.tabSize)&&a.boolean(t.insertSpaces)}e.is=i})(Ae||(Ae={}));var Re;(function(e){function n(r,t,o){return{range:r,target:t,data:o}}e.create=n;function i(r){let t=r;return a.defined(t)&&h.is(t.range)&&(a.undefined(t.target)||a.string(t.target))}e.is=i})(Re||(Re={}));var Pe;(function(e){function n(r,t){return{range:r,parent:t}}e.create=n;function i(r){let t=r;return a.objectLiteral(t)&&h.is(t.range)&&(t.parent===void 0||e.is(t.parent))}e.is=i})(Pe||(Pe={}));var De;(function(e){e.namespace="namespace",e.type="type",e.class="class",e.enum="enum",e.interface="interface",e.struct="struct",e.typeParameter="typeParameter",e.parameter="parameter",e.variable="variable",e.property="property",e.enumMember="enumMember",e.event="event",e.function="function",e.method="method",e.macro="macro",e.keyword="keyword",e.modifier="modifier",e.comment="comment",e.string="string",e.number="number",e.regexp="regexp",e.operator="operator",e.decorator="decorator"})(De||(De={}));var Me;(function(e){e.declaration="declaration",e.definition="definition",e.readonly="readonly",e.static="static",e.deprecated="deprecated",e.abstract="abstract",e.async="async",e.modification="modification",e.documentation="documentation",e.defaultLibrary="defaultLibrary"})(Me||(Me={}));var Ce;(function(e){function n(i){const r=i;return a.objectLiteral(r)&&(r.resultId===void 0||typeof r.resultId=="string")&&Array.isArray(r.data)&&(r.data.length===0||typeof r.data[0]=="number")}e.is=n})(Ce||(Ce={}));var ye;(function(e){function n(r,t){return{range:r,text:t}}e.create=n;function i(r){const t=r;return t!=null&&h.is(t.range)&&a.string(t.text)}e.is=i})(ye||(ye={}));var Fe;(function(e){function n(r,t,o){return{range:r,variableName:t,caseSensitiveLookup:o}}e.create=n;function i(r){const t=r;return t!=null&&h.is(t.range)&&a.boolean(t.caseSensitiveLookup)&&(a.string(t.variableName)||t.variableName===void 0)}e.is=i})(Fe||(Fe={}));var je;(function(e){function n(r,t){return{range:r,expression:t}}e.create=n;function i(r){const t=r;return t!=null&&h.is(t.range)&&(a.string(t.expression)||t.expression===void 0)}e.is=i})(je||(je={}));var Ne;(function(e){function n(r,t){return{frameId:r,stoppedLocation:t}}e.create=n;function i(r){const t=r;return a.defined(t)&&h.is(r.stoppedLocation)}e.is=i})(Ne||(Ne={}));var G;(function(e){e.Type=1,e.Parameter=2;function n(i){return i===1||i===2}e.is=n})(G||(G={}));var J;(function(e){function n(r){return{value:r}}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&(t.tooltip===void 0||a.string(t.tooltip)||P.is(t.tooltip))&&(t.location===void 0||C.is(t.location))&&(t.command===void 0||I.is(t.command))}e.is=i})(J||(J={}));var Oe;(function(e){function n(r,t,o){const s={position:r,label:t};return o!==void 0&&(s.kind=o),s}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&w.is(t.position)&&(a.string(t.label)||a.typedArray(t.label,J.is))&&(t.kind===void 0||G.is(t.kind))&&t.textEdits===void 0||a.typedArray(t.textEdits,E.is)&&(t.tooltip===void 0||a.string(t.tooltip)||P.is(t.tooltip))&&(t.paddingLeft===void 0||a.boolean(t.paddingLeft))&&(t.paddingRight===void 0||a.boolean(t.paddingRight))}e.is=i})(Oe||(Oe={}));var Se;(function(e){function n(i){return{kind:"snippet",value:i}}e.createSnippet=n})(Se||(Se={}));var Ue;(function(e){function n(i,r,t,o){return{insertText:i,filterText:r,range:t,command:o}}e.create=n})(Ue||(Ue={}));var Ve;(function(e){function n(i){return{items:i}}e.create=n})(Ve||(Ve={}));var We;(function(e){e.Invoked=0,e.Automatic=1})(We||(We={}));var He;(function(e){function n(i,r){return{range:i,text:r}}e.create=n})(He||(He={}));var Xe;(function(e){function n(i,r){return{triggerKind:i,selectedCompletionInfo:r}}e.create=n})(Xe||(Xe={}));var $e;(function(e){function n(i){const r=i;return a.objectLiteral(r)&&O.is(r.uri)&&a.string(r.name)}e.is=n})($e||($e={}));var ze;(function(e){function n(o,s,u,f){return new ct(o,s,u,f)}e.create=n;function i(o){let s=o;return!!(a.defined(s)&&a.string(s.uri)&&(a.undefined(s.languageId)||a.string(s.languageId))&&a.uinteger(s.lineCount)&&a.func(s.getText)&&a.func(s.positionAt)&&a.func(s.offsetAt))}e.is=i;function r(o,s){let u=o.getText(),f=t(s,(g,_)=>{let b=g.range.start.line-_.range.start.line;return b===0?g.range.start.character-_.range.start.character:b}),c=u.length;for(let g=f.length-1;g>=0;g--){let _=f[g],b=o.offsetAt(_.range.start),l=o.offsetAt(_.range.end);if(l<=c)u=u.substring(0,b)+_.newText+u.substring(l,u.length);else throw new Error("Overlapping edit");c=b}return u}e.applyEdits=r;function t(o,s){if(o.length<=1)return o;const u=o.length/2|0,f=o.slice(0,u),c=o.slice(u);t(f,s),t(c,s);let g=0,_=0,b=0;for(;g<f.length&&_<c.length;)s(f[g],c[_])<=0?o[b++]=f[g++]:o[b++]=c[_++];for(;g<f.length;)o[b++]=f[g++];for(;_<c.length;)o[b++]=c[_++];return o}})(ze||(ze={}));var ct=class{constructor(e,n,i,r){this._uri=e,this._languageId=n,this._version=i,this._content=r,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let n=this.offsetAt(e.start),i=this.offsetAt(e.end);return this._content.substring(n,i)}return this._content}update(e,n){this._content=e.text,this._version=n,this._lineOffsets=void 0}getLineOffsets(){if(this._lineOffsets===void 0){let e=[],n=this._content,i=!0;for(let r=0;r<n.length;r++){i&&(e.push(r),i=!1);let t=n.charAt(r);i=t==="\r"||t===`
|
|
1
|
+
import{m as et}from"./index-CRX9Ew8L.js";var tt=Object.defineProperty,rt=Object.getOwnPropertyDescriptor,nt=Object.getOwnPropertyNames,it=Object.prototype.hasOwnProperty,ot=(e,n,i,r)=>{if(n&&typeof n=="object"||typeof n=="function")for(let t of nt(n))!it.call(e,t)&&t!==i&&tt(e,t,{get:()=>n[t],enumerable:!(r=rt(n,t))||r.enumerable});return e},at=(e,n,i)=>(ot(e,n,"default"),i),d={};at(d,et);var st=120*1e3,ut=class{constructor(e){this._defaults=e,this._worker=null,this._client=null,this._idleCheckInterval=window.setInterval(()=>this._checkIfIdle(),30*1e3),this._lastUsedTime=0,this._configChangeListener=this._defaults.onDidChange(()=>this._stopWorker())}_stopWorker(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null}dispose(){clearInterval(this._idleCheckInterval),this._configChangeListener.dispose(),this._stopWorker()}_checkIfIdle(){if(!this._worker)return;Date.now()-this._lastUsedTime>st&&this._stopWorker()}_getClient(){return this._lastUsedTime=Date.now(),this._client||(this._worker=d.editor.createWebWorker({moduleId:"vs/language/css/cssWorker",label:this._defaults.languageId,createData:{options:this._defaults.options,languageId:this._defaults.languageId}}),this._client=this._worker.getProxy()),this._client}getLanguageServiceWorker(...e){let n;return this._getClient().then(i=>{n=i}).then(i=>{if(this._worker)return this._worker.withSyncedResources(e)}).then(i=>n)}},T;(function(e){function n(i){return typeof i=="string"}e.is=n})(T||(T={}));var O;(function(e){function n(i){return typeof i=="string"}e.is=n})(O||(O={}));var Y;(function(e){e.MIN_VALUE=-2147483648,e.MAX_VALUE=2147483647;function n(i){return typeof i=="number"&&e.MIN_VALUE<=i&&i<=e.MAX_VALUE}e.is=n})(Y||(Y={}));var M;(function(e){e.MIN_VALUE=0,e.MAX_VALUE=2147483647;function n(i){return typeof i=="number"&&e.MIN_VALUE<=i&&i<=e.MAX_VALUE}e.is=n})(M||(M={}));var w;(function(e){function n(r,t){return r===Number.MAX_VALUE&&(r=M.MAX_VALUE),t===Number.MAX_VALUE&&(t=M.MAX_VALUE),{line:r,character:t}}e.create=n;function i(r){let t=r;return a.objectLiteral(t)&&a.uinteger(t.line)&&a.uinteger(t.character)}e.is=i})(w||(w={}));var h;(function(e){function n(r,t,o,s){if(a.uinteger(r)&&a.uinteger(t)&&a.uinteger(o)&&a.uinteger(s))return{start:w.create(r,t),end:w.create(o,s)};if(w.is(r)&&w.is(t))return{start:r,end:t};throw new Error(`Range#create called with invalid arguments[${r}, ${t}, ${o}, ${s}]`)}e.create=n;function i(r){let t=r;return a.objectLiteral(t)&&w.is(t.start)&&w.is(t.end)}e.is=i})(h||(h={}));var C;(function(e){function n(r,t){return{uri:r,range:t}}e.create=n;function i(r){let t=r;return a.objectLiteral(t)&&h.is(t.range)&&(a.string(t.uri)||a.undefined(t.uri))}e.is=i})(C||(C={}));var Z;(function(e){function n(r,t,o,s){return{targetUri:r,targetRange:t,targetSelectionRange:o,originSelectionRange:s}}e.create=n;function i(r){let t=r;return a.objectLiteral(t)&&h.is(t.targetRange)&&a.string(t.targetUri)&&h.is(t.targetSelectionRange)&&(h.is(t.originSelectionRange)||a.undefined(t.originSelectionRange))}e.is=i})(Z||(Z={}));var S;(function(e){function n(r,t,o,s){return{red:r,green:t,blue:o,alpha:s}}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&a.numberRange(t.red,0,1)&&a.numberRange(t.green,0,1)&&a.numberRange(t.blue,0,1)&&a.numberRange(t.alpha,0,1)}e.is=i})(S||(S={}));var K;(function(e){function n(r,t){return{range:r,color:t}}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&h.is(t.range)&&S.is(t.color)}e.is=i})(K||(K={}));var ee;(function(e){function n(r,t,o){return{label:r,textEdit:t,additionalTextEdits:o}}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&a.string(t.label)&&(a.undefined(t.textEdit)||E.is(t))&&(a.undefined(t.additionalTextEdits)||a.typedArray(t.additionalTextEdits,E.is))}e.is=i})(ee||(ee={}));var A;(function(e){e.Comment="comment",e.Imports="imports",e.Region="region"})(A||(A={}));var te;(function(e){function n(r,t,o,s,u,f){const c={startLine:r,endLine:t};return a.defined(o)&&(c.startCharacter=o),a.defined(s)&&(c.endCharacter=s),a.defined(u)&&(c.kind=u),a.defined(f)&&(c.collapsedText=f),c}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&a.uinteger(t.startLine)&&a.uinteger(t.startLine)&&(a.undefined(t.startCharacter)||a.uinteger(t.startCharacter))&&(a.undefined(t.endCharacter)||a.uinteger(t.endCharacter))&&(a.undefined(t.kind)||a.string(t.kind))}e.is=i})(te||(te={}));var U;(function(e){function n(r,t){return{location:r,message:t}}e.create=n;function i(r){let t=r;return a.defined(t)&&C.is(t.location)&&a.string(t.message)}e.is=i})(U||(U={}));var x;(function(e){e.Error=1,e.Warning=2,e.Information=3,e.Hint=4})(x||(x={}));var re;(function(e){e.Unnecessary=1,e.Deprecated=2})(re||(re={}));var ne;(function(e){function n(i){const r=i;return a.objectLiteral(r)&&a.string(r.href)}e.is=n})(ne||(ne={}));var y;(function(e){function n(r,t,o,s,u,f){let c={range:r,message:t};return a.defined(o)&&(c.severity=o),a.defined(s)&&(c.code=s),a.defined(u)&&(c.source=u),a.defined(f)&&(c.relatedInformation=f),c}e.create=n;function i(r){var t;let o=r;return a.defined(o)&&h.is(o.range)&&a.string(o.message)&&(a.number(o.severity)||a.undefined(o.severity))&&(a.integer(o.code)||a.string(o.code)||a.undefined(o.code))&&(a.undefined(o.codeDescription)||a.string((t=o.codeDescription)===null||t===void 0?void 0:t.href))&&(a.string(o.source)||a.undefined(o.source))&&(a.undefined(o.relatedInformation)||a.typedArray(o.relatedInformation,U.is))}e.is=i})(y||(y={}));var I;(function(e){function n(r,t,...o){let s={title:r,command:t};return a.defined(o)&&o.length>0&&(s.arguments=o),s}e.create=n;function i(r){let t=r;return a.defined(t)&&a.string(t.title)&&a.string(t.command)}e.is=i})(I||(I={}));var E;(function(e){function n(o,s){return{range:o,newText:s}}e.replace=n;function i(o,s){return{range:{start:o,end:o},newText:s}}e.insert=i;function r(o){return{range:o,newText:""}}e.del=r;function t(o){const s=o;return a.objectLiteral(s)&&a.string(s.newText)&&h.is(s.range)}e.is=t})(E||(E={}));var V;(function(e){function n(r,t,o){const s={label:r};return t!==void 0&&(s.needsConfirmation=t),o!==void 0&&(s.description=o),s}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&a.string(t.label)&&(a.boolean(t.needsConfirmation)||t.needsConfirmation===void 0)&&(a.string(t.description)||t.description===void 0)}e.is=i})(V||(V={}));var L;(function(e){function n(i){const r=i;return a.string(r)}e.is=n})(L||(L={}));var ie;(function(e){function n(o,s,u){return{range:o,newText:s,annotationId:u}}e.replace=n;function i(o,s,u){return{range:{start:o,end:o},newText:s,annotationId:u}}e.insert=i;function r(o,s){return{range:o,newText:"",annotationId:s}}e.del=r;function t(o){const s=o;return E.is(s)&&(V.is(s.annotationId)||L.is(s.annotationId))}e.is=t})(ie||(ie={}));var W;(function(e){function n(r,t){return{textDocument:r,edits:t}}e.create=n;function i(r){let t=r;return a.defined(t)&&B.is(t.textDocument)&&Array.isArray(t.edits)}e.is=i})(W||(W={}));var H;(function(e){function n(r,t,o){let s={kind:"create",uri:r};return t!==void 0&&(t.overwrite!==void 0||t.ignoreIfExists!==void 0)&&(s.options=t),o!==void 0&&(s.annotationId=o),s}e.create=n;function i(r){let t=r;return t&&t.kind==="create"&&a.string(t.uri)&&(t.options===void 0||(t.options.overwrite===void 0||a.boolean(t.options.overwrite))&&(t.options.ignoreIfExists===void 0||a.boolean(t.options.ignoreIfExists)))&&(t.annotationId===void 0||L.is(t.annotationId))}e.is=i})(H||(H={}));var X;(function(e){function n(r,t,o,s){let u={kind:"rename",oldUri:r,newUri:t};return o!==void 0&&(o.overwrite!==void 0||o.ignoreIfExists!==void 0)&&(u.options=o),s!==void 0&&(u.annotationId=s),u}e.create=n;function i(r){let t=r;return t&&t.kind==="rename"&&a.string(t.oldUri)&&a.string(t.newUri)&&(t.options===void 0||(t.options.overwrite===void 0||a.boolean(t.options.overwrite))&&(t.options.ignoreIfExists===void 0||a.boolean(t.options.ignoreIfExists)))&&(t.annotationId===void 0||L.is(t.annotationId))}e.is=i})(X||(X={}));var $;(function(e){function n(r,t,o){let s={kind:"delete",uri:r};return t!==void 0&&(t.recursive!==void 0||t.ignoreIfNotExists!==void 0)&&(s.options=t),o!==void 0&&(s.annotationId=o),s}e.create=n;function i(r){let t=r;return t&&t.kind==="delete"&&a.string(t.uri)&&(t.options===void 0||(t.options.recursive===void 0||a.boolean(t.options.recursive))&&(t.options.ignoreIfNotExists===void 0||a.boolean(t.options.ignoreIfNotExists)))&&(t.annotationId===void 0||L.is(t.annotationId))}e.is=i})($||($={}));var z;(function(e){function n(i){let r=i;return r&&(r.changes!==void 0||r.documentChanges!==void 0)&&(r.documentChanges===void 0||r.documentChanges.every(t=>a.string(t.kind)?H.is(t)||X.is(t)||$.is(t):W.is(t)))}e.is=n})(z||(z={}));var oe;(function(e){function n(r){return{uri:r}}e.create=n;function i(r){let t=r;return a.defined(t)&&a.string(t.uri)}e.is=i})(oe||(oe={}));var ae;(function(e){function n(r,t){return{uri:r,version:t}}e.create=n;function i(r){let t=r;return a.defined(t)&&a.string(t.uri)&&a.integer(t.version)}e.is=i})(ae||(ae={}));var B;(function(e){function n(r,t){return{uri:r,version:t}}e.create=n;function i(r){let t=r;return a.defined(t)&&a.string(t.uri)&&(t.version===null||a.integer(t.version))}e.is=i})(B||(B={}));var se;(function(e){function n(r,t,o,s){return{uri:r,languageId:t,version:o,text:s}}e.create=n;function i(r){let t=r;return a.defined(t)&&a.string(t.uri)&&a.string(t.languageId)&&a.integer(t.version)&&a.string(t.text)}e.is=i})(se||(se={}));var q;(function(e){e.PlainText="plaintext",e.Markdown="markdown";function n(i){const r=i;return r===e.PlainText||r===e.Markdown}e.is=n})(q||(q={}));var P;(function(e){function n(i){const r=i;return a.objectLiteral(i)&&q.is(r.kind)&&a.string(r.value)}e.is=n})(P||(P={}));var v;(function(e){e.Text=1,e.Method=2,e.Function=3,e.Constructor=4,e.Field=5,e.Variable=6,e.Class=7,e.Interface=8,e.Module=9,e.Property=10,e.Unit=11,e.Value=12,e.Enum=13,e.Keyword=14,e.Snippet=15,e.Color=16,e.File=17,e.Reference=18,e.Folder=19,e.EnumMember=20,e.Constant=21,e.Struct=22,e.Event=23,e.Operator=24,e.TypeParameter=25})(v||(v={}));var Q;(function(e){e.PlainText=1,e.Snippet=2})(Q||(Q={}));var ue;(function(e){e.Deprecated=1})(ue||(ue={}));var ce;(function(e){function n(r,t,o){return{newText:r,insert:t,replace:o}}e.create=n;function i(r){const t=r;return t&&a.string(t.newText)&&h.is(t.insert)&&h.is(t.replace)}e.is=i})(ce||(ce={}));var de;(function(e){e.asIs=1,e.adjustIndentation=2})(de||(de={}));var le;(function(e){function n(i){const r=i;return r&&(a.string(r.detail)||r.detail===void 0)&&(a.string(r.description)||r.description===void 0)}e.is=n})(le||(le={}));var fe;(function(e){function n(i){return{label:i}}e.create=n})(fe||(fe={}));var ge;(function(e){function n(i,r){return{items:i||[],isIncomplete:!!r}}e.create=n})(ge||(ge={}));var F;(function(e){function n(r){return r.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}e.fromPlainText=n;function i(r){const t=r;return a.string(t)||a.objectLiteral(t)&&a.string(t.language)&&a.string(t.value)}e.is=i})(F||(F={}));var he;(function(e){function n(i){let r=i;return!!r&&a.objectLiteral(r)&&(P.is(r.contents)||F.is(r.contents)||a.typedArray(r.contents,F.is))&&(i.range===void 0||h.is(i.range))}e.is=n})(he||(he={}));var ve;(function(e){function n(i,r){return r?{label:i,documentation:r}:{label:i}}e.create=n})(ve||(ve={}));var pe;(function(e){function n(i,r,...t){let o={label:i};return a.defined(r)&&(o.documentation=r),a.defined(t)?o.parameters=t:o.parameters=[],o}e.create=n})(pe||(pe={}));var R;(function(e){e.Text=1,e.Read=2,e.Write=3})(R||(R={}));var me;(function(e){function n(i,r){let t={range:i};return a.number(r)&&(t.kind=r),t}e.create=n})(me||(me={}));var p;(function(e){e.File=1,e.Module=2,e.Namespace=3,e.Package=4,e.Class=5,e.Method=6,e.Property=7,e.Field=8,e.Constructor=9,e.Enum=10,e.Interface=11,e.Function=12,e.Variable=13,e.Constant=14,e.String=15,e.Number=16,e.Boolean=17,e.Array=18,e.Object=19,e.Key=20,e.Null=21,e.EnumMember=22,e.Struct=23,e.Event=24,e.Operator=25,e.TypeParameter=26})(p||(p={}));var _e;(function(e){e.Deprecated=1})(_e||(_e={}));var be;(function(e){function n(i,r,t,o,s){let u={name:i,kind:r,location:{uri:o,range:t}};return s&&(u.containerName=s),u}e.create=n})(be||(be={}));var we;(function(e){function n(i,r,t,o){return o!==void 0?{name:i,kind:r,location:{uri:t,range:o}}:{name:i,kind:r,location:{uri:t}}}e.create=n})(we||(we={}));var ke;(function(e){function n(r,t,o,s,u,f){let c={name:r,detail:t,kind:o,range:s,selectionRange:u};return f!==void 0&&(c.children=f),c}e.create=n;function i(r){let t=r;return t&&a.string(t.name)&&a.number(t.kind)&&h.is(t.range)&&h.is(t.selectionRange)&&(t.detail===void 0||a.string(t.detail))&&(t.deprecated===void 0||a.boolean(t.deprecated))&&(t.children===void 0||Array.isArray(t.children))&&(t.tags===void 0||Array.isArray(t.tags))}e.is=i})(ke||(ke={}));var xe;(function(e){e.Empty="",e.QuickFix="quickfix",e.Refactor="refactor",e.RefactorExtract="refactor.extract",e.RefactorInline="refactor.inline",e.RefactorRewrite="refactor.rewrite",e.Source="source",e.SourceOrganizeImports="source.organizeImports",e.SourceFixAll="source.fixAll"})(xe||(xe={}));var j;(function(e){e.Invoked=1,e.Automatic=2})(j||(j={}));var Ie;(function(e){function n(r,t,o){let s={diagnostics:r};return t!=null&&(s.only=t),o!=null&&(s.triggerKind=o),s}e.create=n;function i(r){let t=r;return a.defined(t)&&a.typedArray(t.diagnostics,y.is)&&(t.only===void 0||a.typedArray(t.only,a.string))&&(t.triggerKind===void 0||t.triggerKind===j.Invoked||t.triggerKind===j.Automatic)}e.is=i})(Ie||(Ie={}));var Ee;(function(e){function n(r,t,o){let s={title:r},u=!0;return typeof t=="string"?(u=!1,s.kind=t):I.is(t)?s.command=t:s.edit=t,u&&o!==void 0&&(s.kind=o),s}e.create=n;function i(r){let t=r;return t&&a.string(t.title)&&(t.diagnostics===void 0||a.typedArray(t.diagnostics,y.is))&&(t.kind===void 0||a.string(t.kind))&&(t.edit!==void 0||t.command!==void 0)&&(t.command===void 0||I.is(t.command))&&(t.isPreferred===void 0||a.boolean(t.isPreferred))&&(t.edit===void 0||z.is(t.edit))}e.is=i})(Ee||(Ee={}));var Le;(function(e){function n(r,t){let o={range:r};return a.defined(t)&&(o.data=t),o}e.create=n;function i(r){let t=r;return a.defined(t)&&h.is(t.range)&&(a.undefined(t.command)||I.is(t.command))}e.is=i})(Le||(Le={}));var Ae;(function(e){function n(r,t){return{tabSize:r,insertSpaces:t}}e.create=n;function i(r){let t=r;return a.defined(t)&&a.uinteger(t.tabSize)&&a.boolean(t.insertSpaces)}e.is=i})(Ae||(Ae={}));var Re;(function(e){function n(r,t,o){return{range:r,target:t,data:o}}e.create=n;function i(r){let t=r;return a.defined(t)&&h.is(t.range)&&(a.undefined(t.target)||a.string(t.target))}e.is=i})(Re||(Re={}));var Pe;(function(e){function n(r,t){return{range:r,parent:t}}e.create=n;function i(r){let t=r;return a.objectLiteral(t)&&h.is(t.range)&&(t.parent===void 0||e.is(t.parent))}e.is=i})(Pe||(Pe={}));var De;(function(e){e.namespace="namespace",e.type="type",e.class="class",e.enum="enum",e.interface="interface",e.struct="struct",e.typeParameter="typeParameter",e.parameter="parameter",e.variable="variable",e.property="property",e.enumMember="enumMember",e.event="event",e.function="function",e.method="method",e.macro="macro",e.keyword="keyword",e.modifier="modifier",e.comment="comment",e.string="string",e.number="number",e.regexp="regexp",e.operator="operator",e.decorator="decorator"})(De||(De={}));var Me;(function(e){e.declaration="declaration",e.definition="definition",e.readonly="readonly",e.static="static",e.deprecated="deprecated",e.abstract="abstract",e.async="async",e.modification="modification",e.documentation="documentation",e.defaultLibrary="defaultLibrary"})(Me||(Me={}));var Ce;(function(e){function n(i){const r=i;return a.objectLiteral(r)&&(r.resultId===void 0||typeof r.resultId=="string")&&Array.isArray(r.data)&&(r.data.length===0||typeof r.data[0]=="number")}e.is=n})(Ce||(Ce={}));var ye;(function(e){function n(r,t){return{range:r,text:t}}e.create=n;function i(r){const t=r;return t!=null&&h.is(t.range)&&a.string(t.text)}e.is=i})(ye||(ye={}));var Fe;(function(e){function n(r,t,o){return{range:r,variableName:t,caseSensitiveLookup:o}}e.create=n;function i(r){const t=r;return t!=null&&h.is(t.range)&&a.boolean(t.caseSensitiveLookup)&&(a.string(t.variableName)||t.variableName===void 0)}e.is=i})(Fe||(Fe={}));var je;(function(e){function n(r,t){return{range:r,expression:t}}e.create=n;function i(r){const t=r;return t!=null&&h.is(t.range)&&(a.string(t.expression)||t.expression===void 0)}e.is=i})(je||(je={}));var Ne;(function(e){function n(r,t){return{frameId:r,stoppedLocation:t}}e.create=n;function i(r){const t=r;return a.defined(t)&&h.is(r.stoppedLocation)}e.is=i})(Ne||(Ne={}));var G;(function(e){e.Type=1,e.Parameter=2;function n(i){return i===1||i===2}e.is=n})(G||(G={}));var J;(function(e){function n(r){return{value:r}}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&(t.tooltip===void 0||a.string(t.tooltip)||P.is(t.tooltip))&&(t.location===void 0||C.is(t.location))&&(t.command===void 0||I.is(t.command))}e.is=i})(J||(J={}));var Oe;(function(e){function n(r,t,o){const s={position:r,label:t};return o!==void 0&&(s.kind=o),s}e.create=n;function i(r){const t=r;return a.objectLiteral(t)&&w.is(t.position)&&(a.string(t.label)||a.typedArray(t.label,J.is))&&(t.kind===void 0||G.is(t.kind))&&t.textEdits===void 0||a.typedArray(t.textEdits,E.is)&&(t.tooltip===void 0||a.string(t.tooltip)||P.is(t.tooltip))&&(t.paddingLeft===void 0||a.boolean(t.paddingLeft))&&(t.paddingRight===void 0||a.boolean(t.paddingRight))}e.is=i})(Oe||(Oe={}));var Se;(function(e){function n(i){return{kind:"snippet",value:i}}e.createSnippet=n})(Se||(Se={}));var Ue;(function(e){function n(i,r,t,o){return{insertText:i,filterText:r,range:t,command:o}}e.create=n})(Ue||(Ue={}));var Ve;(function(e){function n(i){return{items:i}}e.create=n})(Ve||(Ve={}));var We;(function(e){e.Invoked=0,e.Automatic=1})(We||(We={}));var He;(function(e){function n(i,r){return{range:i,text:r}}e.create=n})(He||(He={}));var Xe;(function(e){function n(i,r){return{triggerKind:i,selectedCompletionInfo:r}}e.create=n})(Xe||(Xe={}));var $e;(function(e){function n(i){const r=i;return a.objectLiteral(r)&&O.is(r.uri)&&a.string(r.name)}e.is=n})($e||($e={}));var ze;(function(e){function n(o,s,u,f){return new ct(o,s,u,f)}e.create=n;function i(o){let s=o;return!!(a.defined(s)&&a.string(s.uri)&&(a.undefined(s.languageId)||a.string(s.languageId))&&a.uinteger(s.lineCount)&&a.func(s.getText)&&a.func(s.positionAt)&&a.func(s.offsetAt))}e.is=i;function r(o,s){let u=o.getText(),f=t(s,(g,_)=>{let b=g.range.start.line-_.range.start.line;return b===0?g.range.start.character-_.range.start.character:b}),c=u.length;for(let g=f.length-1;g>=0;g--){let _=f[g],b=o.offsetAt(_.range.start),l=o.offsetAt(_.range.end);if(l<=c)u=u.substring(0,b)+_.newText+u.substring(l,u.length);else throw new Error("Overlapping edit");c=b}return u}e.applyEdits=r;function t(o,s){if(o.length<=1)return o;const u=o.length/2|0,f=o.slice(0,u),c=o.slice(u);t(f,s),t(c,s);let g=0,_=0,b=0;for(;g<f.length&&_<c.length;)s(f[g],c[_])<=0?o[b++]=f[g++]:o[b++]=c[_++];for(;g<f.length;)o[b++]=f[g++];for(;_<c.length;)o[b++]=c[_++];return o}})(ze||(ze={}));var ct=class{constructor(e,n,i,r){this._uri=e,this._languageId=n,this._version=i,this._content=r,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let n=this.offsetAt(e.start),i=this.offsetAt(e.end);return this._content.substring(n,i)}return this._content}update(e,n){this._content=e.text,this._version=n,this._lineOffsets=void 0}getLineOffsets(){if(this._lineOffsets===void 0){let e=[],n=this._content,i=!0;for(let r=0;r<n.length;r++){i&&(e.push(r),i=!1);let t=n.charAt(r);i=t==="\r"||t===`
|
|
2
2
|
`,t==="\r"&&r+1<n.length&&n.charAt(r+1)===`
|
|
3
3
|
`&&r++}i&&n.length>0&&e.push(n.length),this._lineOffsets=e}return this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);let n=this.getLineOffsets(),i=0,r=n.length;if(r===0)return w.create(0,e);for(;i<r;){let o=Math.floor((i+r)/2);n[o]>e?r=o:i=o+1}let t=i-1;return w.create(t,e-n[t])}offsetAt(e){let n=this.getLineOffsets();if(e.line>=n.length)return this._content.length;if(e.line<0)return 0;let i=n[e.line],r=e.line+1<n.length?n[e.line+1]:this._content.length;return Math.max(Math.min(i+e.character,r),i)}get lineCount(){return this.getLineOffsets().length}},a;(function(e){const n=Object.prototype.toString;function i(l){return typeof l<"u"}e.defined=i;function r(l){return typeof l>"u"}e.undefined=r;function t(l){return l===!0||l===!1}e.boolean=t;function o(l){return n.call(l)==="[object String]"}e.string=o;function s(l){return n.call(l)==="[object Number]"}e.number=s;function u(l,N,Ke){return n.call(l)==="[object Number]"&&N<=l&&l<=Ke}e.numberRange=u;function f(l){return n.call(l)==="[object Number]"&&-2147483648<=l&&l<=2147483647}e.integer=f;function c(l){return n.call(l)==="[object Number]"&&0<=l&&l<=2147483647}e.uinteger=c;function g(l){return n.call(l)==="[object Function]"}e.func=g;function _(l){return l!==null&&typeof l=="object"}e.objectLiteral=_;function b(l,N){return Array.isArray(l)&&l.every(N)}e.typedArray=b})(a||(a={}));var dt=class{constructor(e,n,i){this._languageId=e,this._worker=n,this._disposables=[],this._listener=Object.create(null);const r=o=>{let s=o.getLanguageId();if(s!==this._languageId)return;let u;this._listener[o.uri.toString()]=o.onDidChangeContent(()=>{window.clearTimeout(u),u=window.setTimeout(()=>this._doValidate(o.uri,s),500)}),this._doValidate(o.uri,s)},t=o=>{d.editor.setModelMarkers(o,this._languageId,[]);let s=o.uri.toString(),u=this._listener[s];u&&(u.dispose(),delete this._listener[s])};this._disposables.push(d.editor.onDidCreateModel(r)),this._disposables.push(d.editor.onWillDisposeModel(t)),this._disposables.push(d.editor.onDidChangeModelLanguage(o=>{t(o.model),r(o.model)})),this._disposables.push(i(o=>{d.editor.getModels().forEach(s=>{s.getLanguageId()===this._languageId&&(t(s),r(s))})})),this._disposables.push({dispose:()=>{d.editor.getModels().forEach(t);for(let o in this._listener)this._listener[o].dispose()}}),d.editor.getModels().forEach(r)}dispose(){this._disposables.forEach(e=>e&&e.dispose()),this._disposables.length=0}_doValidate(e,n){this._worker(e).then(i=>i.doValidation(e.toString())).then(i=>{const r=i.map(o=>ft(e,o));let t=d.editor.getModel(e);t&&t.getLanguageId()===n&&d.editor.setModelMarkers(t,n,r)}).then(void 0,i=>{console.error(i)})}};function lt(e){switch(e){case x.Error:return d.MarkerSeverity.Error;case x.Warning:return d.MarkerSeverity.Warning;case x.Information:return d.MarkerSeverity.Info;case x.Hint:return d.MarkerSeverity.Hint;default:return d.MarkerSeverity.Info}}function ft(e,n){let i=typeof n.code=="number"?String(n.code):n.code;return{severity:lt(n.severity),startLineNumber:n.range.start.line+1,startColumn:n.range.start.character+1,endLineNumber:n.range.end.line+1,endColumn:n.range.end.character+1,message:n.message,code:i,source:n.source}}var gt=class{constructor(e,n){this._worker=e,this._triggerCharacters=n}get triggerCharacters(){return this._triggerCharacters}provideCompletionItems(e,n,i,r){const t=e.uri;return this._worker(t).then(o=>o.doComplete(t.toString(),k(n))).then(o=>{if(!o)return;const s=e.getWordUntilPosition(n),u=new d.Range(n.lineNumber,s.startColumn,n.lineNumber,s.endColumn),f=o.items.map(c=>{const g={label:c.label,insertText:c.insertText||c.label,sortText:c.sortText,filterText:c.filterText,documentation:c.documentation,detail:c.detail,command:pt(c.command),range:u,kind:vt(c.kind)};return c.textEdit&&(ht(c.textEdit)?g.range={insert:m(c.textEdit.insert),replace:m(c.textEdit.replace)}:g.range=m(c.textEdit.range),g.insertText=c.textEdit.newText),c.additionalTextEdits&&(g.additionalTextEdits=c.additionalTextEdits.map(D)),c.insertTextFormat===Q.Snippet&&(g.insertTextRules=d.languages.CompletionItemInsertTextRule.InsertAsSnippet),g});return{isIncomplete:o.isIncomplete,suggestions:f}})}};function k(e){if(e)return{character:e.column-1,line:e.lineNumber-1}}function Qe(e){if(e)return{start:{line:e.startLineNumber-1,character:e.startColumn-1},end:{line:e.endLineNumber-1,character:e.endColumn-1}}}function m(e){if(e)return new d.Range(e.start.line+1,e.start.character+1,e.end.line+1,e.end.character+1)}function ht(e){return typeof e.insert<"u"&&typeof e.replace<"u"}function vt(e){const n=d.languages.CompletionItemKind;switch(e){case v.Text:return n.Text;case v.Method:return n.Method;case v.Function:return n.Function;case v.Constructor:return n.Constructor;case v.Field:return n.Field;case v.Variable:return n.Variable;case v.Class:return n.Class;case v.Interface:return n.Interface;case v.Module:return n.Module;case v.Property:return n.Property;case v.Unit:return n.Unit;case v.Value:return n.Value;case v.Enum:return n.Enum;case v.Keyword:return n.Keyword;case v.Snippet:return n.Snippet;case v.Color:return n.Color;case v.File:return n.File;case v.Reference:return n.Reference}return n.Property}function D(e){if(e)return{range:m(e.range),text:e.newText}}function pt(e){return e&&e.command==="editor.action.triggerSuggest"?{id:e.command,title:e.title,arguments:e.arguments}:void 0}var mt=class{constructor(e){this._worker=e}provideHover(e,n,i){let r=e.uri;return this._worker(r).then(t=>t.doHover(r.toString(),k(n))).then(t=>{if(t)return{range:m(t.range),contents:bt(t.contents)}})}};function _t(e){return e&&typeof e=="object"&&typeof e.kind=="string"}function Be(e){return typeof e=="string"?{value:e}:_t(e)?e.kind==="plaintext"?{value:e.value.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}:{value:e.value}:{value:"```"+e.language+`
|
|
4
4
|
`+e.value+"\n```\n"}}function bt(e){if(e)return Array.isArray(e)?e.map(Be):[Be(e)]}var wt=class{constructor(e){this._worker=e}provideDocumentHighlights(e,n,i){const r=e.uri;return this._worker(r).then(t=>t.findDocumentHighlights(r.toString(),k(n))).then(t=>{if(t)return t.map(o=>({range:m(o.range),kind:kt(o.kind)}))})}};function kt(e){switch(e){case R.Read:return d.languages.DocumentHighlightKind.Read;case R.Write:return d.languages.DocumentHighlightKind.Write;case R.Text:return d.languages.DocumentHighlightKind.Text}return d.languages.DocumentHighlightKind.Text}var xt=class{constructor(e){this._worker=e}provideDefinition(e,n,i){const r=e.uri;return this._worker(r).then(t=>t.findDefinition(r.toString(),k(n))).then(t=>{if(t)return[Ge(t)]})}};function Ge(e){return{uri:d.Uri.parse(e.uri),range:m(e.range)}}var It=class{constructor(e){this._worker=e}provideReferences(e,n,i,r){const t=e.uri;return this._worker(t).then(o=>o.findReferences(t.toString(),k(n))).then(o=>{if(o)return o.map(Ge)})}},Et=class{constructor(e){this._worker=e}provideRenameEdits(e,n,i,r){const t=e.uri;return this._worker(t).then(o=>o.doRename(t.toString(),k(n),i)).then(o=>Lt(o))}};function Lt(e){if(!e||!e.changes)return;let n=[];for(let i in e.changes){const r=d.Uri.parse(i);for(let t of e.changes[i])n.push({resource:r,versionId:void 0,textEdit:{range:m(t.range),text:t.newText}})}return{edits:n}}var At=class{constructor(e){this._worker=e}provideDocumentSymbols(e,n){const i=e.uri;return this._worker(i).then(r=>r.findDocumentSymbols(i.toString())).then(r=>{if(r)return r.map(t=>Rt(t)?Je(t):{name:t.name,detail:"",containerName:t.containerName,kind:Te(t.kind),range:m(t.location.range),selectionRange:m(t.location.range),tags:[]})})}};function Rt(e){return"children"in e}function Je(e){return{name:e.name,detail:e.detail??"",kind:Te(e.kind),range:m(e.range),selectionRange:m(e.selectionRange),tags:e.tags??[],children:(e.children??[]).map(n=>Je(n))}}function Te(e){let n=d.languages.SymbolKind;switch(e){case p.File:return n.File;case p.Module:return n.Module;case p.Namespace:return n.Namespace;case p.Package:return n.Package;case p.Class:return n.Class;case p.Method:return n.Method;case p.Property:return n.Property;case p.Field:return n.Field;case p.Constructor:return n.Constructor;case p.Enum:return n.Enum;case p.Interface:return n.Interface;case p.Function:return n.Function;case p.Variable:return n.Variable;case p.Constant:return n.Constant;case p.String:return n.String;case p.Number:return n.Number;case p.Boolean:return n.Boolean;case p.Array:return n.Array}return n.Function}var Nt=class{constructor(e){this._worker=e}provideLinks(e,n){const i=e.uri;return this._worker(i).then(r=>r.findDocumentLinks(i.toString())).then(r=>{if(r)return{links:r.map(t=>({range:m(t.range),url:t.target}))}})}},Pt=class{constructor(e){this._worker=e}provideDocumentFormattingEdits(e,n,i){const r=e.uri;return this._worker(r).then(t=>t.format(r.toString(),null,Ye(n)).then(o=>{if(!(!o||o.length===0))return o.map(D)}))}},Dt=class{constructor(e){this._worker=e,this.canFormatMultipleRanges=!1}provideDocumentRangeFormattingEdits(e,n,i,r){const t=e.uri;return this._worker(t).then(o=>o.format(t.toString(),Qe(n),Ye(i)).then(s=>{if(!(!s||s.length===0))return s.map(D)}))}};function Ye(e){return{tabSize:e.tabSize,insertSpaces:e.insertSpaces}}var Mt=class{constructor(e){this._worker=e}provideDocumentColors(e,n){const i=e.uri;return this._worker(i).then(r=>r.findDocumentColors(i.toString())).then(r=>{if(r)return r.map(t=>({color:t.color,range:m(t.range)}))})}provideColorPresentations(e,n,i){const r=e.uri;return this._worker(r).then(t=>t.getColorPresentations(r.toString(),n.color,Qe(n.range))).then(t=>{if(t)return t.map(o=>{let s={label:o.label};return o.textEdit&&(s.textEdit=D(o.textEdit)),o.additionalTextEdits&&(s.additionalTextEdits=o.additionalTextEdits.map(D)),s})})}},Ct=class{constructor(e){this._worker=e}provideFoldingRanges(e,n,i){const r=e.uri;return this._worker(r).then(t=>t.getFoldingRanges(r.toString(),n)).then(t=>{if(t)return t.map(o=>{const s={start:o.startLine+1,end:o.endLine+1};return typeof o.kind<"u"&&(s.kind=yt(o.kind)),s})})}};function yt(e){switch(e){case A.Comment:return d.languages.FoldingRangeKind.Comment;case A.Imports:return d.languages.FoldingRangeKind.Imports;case A.Region:return d.languages.FoldingRangeKind.Region}}var Ft=class{constructor(e){this._worker=e}provideSelectionRanges(e,n,i){const r=e.uri;return this._worker(r).then(t=>t.getSelectionRanges(r.toString(),n.map(k))).then(t=>{if(t)return t.map(o=>{const s=[];for(;o;)s.push({range:m(o.range)}),o=o.parent;return s})})}};function Ot(e){const n=[],i=[],r=new ut(e);n.push(r);const t=(...s)=>r.getLanguageServiceWorker(...s);function o(){const{languageId:s,modeConfiguration:u}=e;Ze(i),u.completionItems&&i.push(d.languages.registerCompletionItemProvider(s,new gt(t,["/","-",":"]))),u.hovers&&i.push(d.languages.registerHoverProvider(s,new mt(t))),u.documentHighlights&&i.push(d.languages.registerDocumentHighlightProvider(s,new wt(t))),u.definitions&&i.push(d.languages.registerDefinitionProvider(s,new xt(t))),u.references&&i.push(d.languages.registerReferenceProvider(s,new It(t))),u.documentSymbols&&i.push(d.languages.registerDocumentSymbolProvider(s,new At(t))),u.rename&&i.push(d.languages.registerRenameProvider(s,new Et(t))),u.colors&&i.push(d.languages.registerColorProvider(s,new Mt(t))),u.foldingRanges&&i.push(d.languages.registerFoldingRangeProvider(s,new Ct(t))),u.diagnostics&&i.push(new dt(s,t,e.onDidChange)),u.selectionRanges&&i.push(d.languages.registerSelectionRangeProvider(s,new Ft(t))),u.documentFormattingEdits&&i.push(d.languages.registerDocumentFormattingEditProvider(s,new Pt(t))),u.documentRangeFormattingEdits&&i.push(d.languages.registerDocumentRangeFormattingEditProvider(s,new Dt(t)))}return o(),n.push(qe(i)),qe(n)}function qe(e){return{dispose:()=>Ze(e)}}function Ze(e){for(;e.length;)e.pop().dispose()}export{gt as CompletionAdapter,xt as DefinitionAdapter,dt as DiagnosticsAdapter,Mt as DocumentColorAdapter,Pt as DocumentFormattingEditProvider,wt as DocumentHighlightAdapter,Nt as DocumentLinkAdapter,Dt as DocumentRangeFormattingEditProvider,At as DocumentSymbolAdapter,Ct as FoldingRangeAdapter,mt as HoverAdapter,It as ReferenceAdapter,Et as RenameAdapter,Ft as SelectionRangeAdapter,ut as WorkerManager,k as fromPosition,Qe as fromRange,Ot as setupMode,m as toRange,D as toTextEdit};
|