From 33058f2b292b3a581333bdfb21b8f671898c5060 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:40:17 -0500 Subject: initial commit --- files/ja/web/api/deviceproximityevent/index.html | 63 ++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 files/ja/web/api/deviceproximityevent/index.html (limited to 'files/ja/web/api/deviceproximityevent/index.html') diff --git a/files/ja/web/api/deviceproximityevent/index.html b/files/ja/web/api/deviceproximityevent/index.html new file mode 100644 index 0000000000..63a5138967 --- /dev/null +++ b/files/ja/web/api/deviceproximityevent/index.html @@ -0,0 +1,63 @@ +--- +title: DeviceProximityEvent +slug: Web/API/DeviceProximityEvent +tags: + - API + - Interface + - Proximity Event + - Reference +translation_of: Web/API/DeviceProximityEvent +--- +

{{APIRef("Proximity Events")}}{{SeeCompatTable}}

+ +

DeviceProximityEvent インターフェースは、端末の近接センサーを使用して近くの物理オブジェクトの距離についての情報を提供します。

+ +

プロパティ

+ +
+
{{domxref("DeviceProximityEvent.max")}} {{readonlyinline}}
+
センサーが報告できる最大検出距離 (センチメートル単位)。
+
{{domxref("DeviceProximityEvent.min")}} {{readonlyinline}}
+
センサーが報告できる最小検出距離 (センチメートル単位)。通常は 0。
+
{{domxref("DeviceProximityEvent.value")}} {{readonlyinline}}
+
現在の端末近接度 (センチメートル単位)
+
+ +

+ +
window.addEventListener('deviceproximity', function(event) {
+  console.log("value: " + event.value, "max: " + event.max, "min: " + event.min);
+});
+ +

仕様書

+ + + + + + + + + + + + + + + + +
仕様書状態備考
{{ SpecName('Proximity Events', '', 'Proximity Events') }}{{ Spec2('Proximity Events') }}初回定義
+ +

ブラウザーの対応

+ + + +

{{Compat("api.DeviceProximityEvent")}}

+ +

関連情報

+ + -- cgit v1.2.3-54-g00ecf