allow markup in instructions

This commit is contained in:
Bruno Windels
2020-12-07 14:35:08 +01:00
parent 732b8a48ff
commit 42994c4474
4 changed files with 28 additions and 7 deletions
+3 -3
View File
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/
import {Maturity, Platform, LinkKind, FlathubLink} from "../types.js";
import {Maturity, Platform, LinkKind, FlathubLink, style} from "../types.js";
/**
* Information on how to deep link to a given matrix client.
@@ -33,8 +33,8 @@ export class Nheko {
getLinkInstructions(platform, link) {
switch (link.kind) {
case LinkKind.User: return `Type /invite ${link.identifier}`;
case LinkKind.Room: return `Type /join ${link.identifier}`;
case LinkKind.User: return [`Type `, style.code(`/invite ${link.identifier}`)];
case LinkKind.Room: return [`Type `, style.code(`/join ${link.identifier}`)];
}
}