slack-block-builder
Advanced tools
Comparing version 0.1.1 to 0.1.2
# Change Log | ||
## v0.1.2 - 2020-06-12 | ||
* Add `inChannel()` method to `Message` object. | ||
## v0.1.1 - 2020-06-10 | ||
* Fix issue where strings passed to the 'fields()' method of a Section object would be mutated into plain text objects instead of markdown text objects. | ||
* Fix issue where strings passed to the 'elements()' method of a Context object would be mutated into plain text objects instead of markdown text objects. | ||
* Fix type in JSDoc for TextInput Element object (intiialValue => initialValue). | ||
* Update tests to accommodate for these changes. | ||
* Update description and keywords in package.json. | ||
* Update README.md. | ||
* Fix issue where strings passed to the `fields()` method of a `Section` object would be mutated into plain text objects instead of markdown text objects. | ||
* Fix issue where strings passed to the `elements()` method of a `Context` object would be mutated into plain text objects instead of markdown text objects. | ||
* Fix type in JSDoc for `TextInput` object (intiialValue => initialValue). | ||
@@ -12,0 +13,0 @@ ## v0.1.0 - 2020-06-09 |
{ | ||
"name": "slack-block-builder", | ||
"version": "0.1.1", | ||
"version": "0.1.2", | ||
"description": "Lightweight, zero-dependency library for creating Slack messages and modals, with a builder interface inspired by SwiftUI.", | ||
@@ -5,0 +5,0 @@ "author": { |
@@ -114,3 +114,3 @@ const { Surface } = require('./base'); | ||
/** | ||
* Sets the message to only visible by the user who invoked the action | ||
* Sets the message to only be visible by the user who invoked the action | ||
* | ||
@@ -127,2 +127,14 @@ * {@link https://api.slack.com/messaging/composing|View in Slack API Documentation} | ||
/** | ||
* Sets the message to visible to everyone in the channel | ||
* | ||
* {@link https://api.slack.com/messaging/composing|View in Slack API Documentation} | ||
* | ||
* @return {this} The instance on which the method is called | ||
*/ | ||
inChannel() { | ||
return this.set(enumValues.inChannel, props.responseType); | ||
} | ||
/** | ||
* Sets a time for the message to be posted, as a scheduled message | ||
@@ -129,0 +141,0 @@ * |
@@ -63,2 +63,3 @@ module.exports = { | ||
ephemeral: 'ephemeral', | ||
inChannel: 'inChannel', | ||
}; |
@@ -6,2 +6,3 @@ module.exports = { | ||
ephemeral: 'ephemeral', | ||
inChannel: 'in_channel', | ||
}; |
@@ -89,3 +89,3 @@ const Validator = require('../lib/validator'); | ||
isResponseTypeEnum: new Validator({ | ||
condition: (value) => value === enumValues.ephemeral, | ||
condition: (value) => [enumValues.ephemeral, enumValues.inChannel].includes(value), | ||
message: 'String with value of \'ephemeral\'', | ||
@@ -92,0 +92,0 @@ }), |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
167935
3639