adding bare docs
This commit is contained in:
		@@ -9,11 +9,4 @@ sensors.touchSensor1.onEvent(TouchSensorEvent.Pressed, function () {
 | 
			
		||||
sensors.touchSensor1.onEvent(TouchSensorEvent.Released, function () {
 | 
			
		||||
    brick.showImage(images.expressionsSick)
 | 
			
		||||
})
 | 
			
		||||
loops.forever(function () {
 | 
			
		||||
    if (sensors.touchSensor1.isTouched()) {
 | 
			
		||||
        brick.setStatusLight(LightsPattern.Green)
 | 
			
		||||
    } else {
 | 
			
		||||
        brick.setStatusLight(LightsPattern.Orange)
 | 
			
		||||
    }
 | 
			
		||||
})
 | 
			
		||||
```
 | 
			
		||||
@@ -1,3 +1,7 @@
 | 
			
		||||
# Reference
 | 
			
		||||
 | 
			
		||||
TODO
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
## See Also
 | 
			
		||||
 | 
			
		||||
[touch sensor](/reference/sensors/touch-sensor)
 | 
			
		||||
							
								
								
									
										15
									
								
								libs/touch-sensor/docs/reference/sensors/touch-sensor.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								libs/touch-sensor/docs/reference/sensors/touch-sensor.md
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,15 @@
 | 
			
		||||
# Touch Sensor
 | 
			
		||||
 | 
			
		||||
```cards
 | 
			
		||||
sensors.touchSensor1.onEvent(TouchSensorEvent.Pressed, function () {
 | 
			
		||||
    brick.showImage(images.expressionsBigSmile)
 | 
			
		||||
})
 | 
			
		||||
sensors.touchSensor1.isPressed();
 | 
			
		||||
sensors.touchSensor1.wasPressed();
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
## See Also
 | 
			
		||||
 | 
			
		||||
[on Event](/reference/sensors/touch-sensor/on-event),
 | 
			
		||||
[is pressed](reference/sensors/touch-sensor/is-pressed),
 | 
			
		||||
[was pressed](reference/sensors/touch-sensor/was-pressed)
 | 
			
		||||
@@ -0,0 +1,11 @@
 | 
			
		||||
# is Pressed
 | 
			
		||||
 | 
			
		||||
```blocks
 | 
			
		||||
loops.forever(function () {
 | 
			
		||||
    if (sensors.touchSensor1.isPressed()) {
 | 
			
		||||
        brick.setStatusLight(LightsPattern.Green)
 | 
			
		||||
    } else {
 | 
			
		||||
        brick.setStatusLight(LightsPattern.Orange)
 | 
			
		||||
    }
 | 
			
		||||
})
 | 
			
		||||
```
 | 
			
		||||
@@ -0,0 +1,16 @@
 | 
			
		||||
# On Event
 | 
			
		||||
 | 
			
		||||
```sig
 | 
			
		||||
sensors.touchSensor1.onEvent(TouchSensorEvent.Released, function () { })
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
# Parameters
 | 
			
		||||
 | 
			
		||||
## Examples
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
```blocks
 | 
			
		||||
sensors.touchSensor1.onEvent(TouchSensorEvent.Released, function () {
 | 
			
		||||
    brick.showImage(images.expressionsSick)
 | 
			
		||||
})
 | 
			
		||||
```
 | 
			
		||||
@@ -0,0 +1,11 @@
 | 
			
		||||
# was Pressed
 | 
			
		||||
 | 
			
		||||
```blocks
 | 
			
		||||
loops.forever(function () {
 | 
			
		||||
    if (sensors.touchSensor1.wasPressed()) {
 | 
			
		||||
        brick.setStatusLight(LightsPattern.Green)
 | 
			
		||||
    } else {
 | 
			
		||||
        brick.setStatusLight(LightsPattern.Orange)
 | 
			
		||||
    }
 | 
			
		||||
})
 | 
			
		||||
```
 | 
			
		||||
		Reference in New Issue
	
	Block a user