Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

adf-builder

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

adf-builder - npm Package Compare versions

Comparing version 3.1.0 to 3.2.0

dist/_chai/index.d.ts

15

CHANGELOG.md
# Change Log
## 3.2.0
* Merged #10: Support for user in application card title
* Merged #7: Doc update: colons around emoji names
* Upgraded dependencies
* Use `better-ajv-errors` for tests against ADF schema
## 3.1.0
* Added `strike` mark for text node
## 3.0.1
* Added action mark parameters
## 3.0.0

@@ -4,0 +19,0 @@

35

dist/nodes/application-card.d.ts

@@ -25,4 +25,4 @@ import { TopLevelNode, Typed } from './index';

export declare class Action {
private actionTitle;
private actionTarget;
private actionTitle?;
private actionTarget?;
private actionParameters?;

@@ -35,7 +35,7 @@ title(title: string): this;

export declare class Detail {
private detailTitle;
private detailText;
private detailLozenge;
private detailIcon;
private detailBadge;
private detailTitle?;
private detailText?;
private detailLozenge?;
private detailIcon?;
private detailBadge?;
private detailUsers;

@@ -52,3 +52,3 @@ title(text: string): this;

private text;
private contextIcon;
private contextIcon?;
constructor(text: string);

@@ -58,13 +58,21 @@ icon(icon: Icon): this;

}
export declare class TitleUser {
private titleUserIcon;
private titleUserId?;
constructor(titleUserIcon: Icon);
id(id: string): this;
toJSON(): any;
}
export declare class ApplicationCard extends TopLevelNode {
private readonly title;
private readonly text;
private linkUrl;
private backgroundUrl;
private previewUrl;
private linkUrl?;
private backgroundUrl?;
private previewUrl?;
private isCollapsible;
private descriptionText;
private descriptionText?;
private userInTitle?;
private details;
private actions;
private cardContext;
private cardContext?;
constructor(title: string, text?: string | undefined);

@@ -76,2 +84,3 @@ link(url: string): this;

description(text: string): this;
titleUser(icon: Icon): TitleUser;
detail(): Detail;

@@ -78,0 +87,0 @@ action(): Action;

@@ -112,2 +112,21 @@ "use strict";

exports.Context = Context;
class TitleUser {
constructor(titleUserIcon) {
this.titleUserIcon = titleUserIcon;
}
id(id) {
this.titleUserId = id;
return this;
}
toJSON() {
const titleUser = {
icon: this.titleUserIcon
};
if (this.titleUserId) {
titleUser.id = this.titleUserId;
}
return titleUser;
}
}
exports.TitleUser = TitleUser;
class ApplicationCard extends index_1.TopLevelNode {

@@ -142,2 +161,7 @@ constructor(title, text) {

}
titleUser(icon) {
const titleUser = new TitleUser(icon);
this.userInTitle = titleUser;
return titleUser;
}
detail() {

@@ -189,2 +213,5 @@ const detail = new Detail();

}
if (this.userInTitle) {
card.attrs.title.user = this.userInTitle.toJSON();
}
if (this.details.length > 0) {

@@ -191,0 +218,0 @@ card.attrs.details = this.details.map(detail => detail.toJSON());

{
"name": "adf-builder",
"version": "3.1.0",
"version": "3.2.0",
"description": "Atlassian Document Format Builder",

@@ -20,16 +20,20 @@ "main": "dist/index.js",

"devDependencies": {
"@types/chai": "^4.0.1",
"@types/mocha": "^2.2.41",
"ajv": "4",
"axios": "^0.16.2",
"chai": "^4.1.0",
"mocha": "^3.4.2",
"nyc": "^11.1.0",
"ts-node": "^3.3.0",
"tslint": "^5.5.0",
"typescript": "^2.4.2"
"@types/chai": "^4.1.3",
"@types/mocha": "^5.2.0",
"ajv": "^4.11.8",
"axios": "^0.18.0",
"better-ajv-errors": "^0.5.1",
"chai": "^4.1.2",
"mocha": "^5.1.1",
"nyc": "^11.7.1",
"ts-node": "^6.0.1",
"tslint": "^5.9.1",
"typescript": "^2.8.3"
},
"nyc": {
"include": "src/**/*.ts",
"exclude": "src/**/_specs",
"exclude": [
"src/**/_specs",
"src/_chai"
],
"extension": ".ts",

@@ -36,0 +40,0 @@ "require": "ts-node/register"

# Atlassian Document Format Builder (JavaScript)
[![npm](https://img.shields.io/npm/v/adf-builder.svg)](https://www.npmjs.com/package/adf-builder)
[![npm](https://img.shields.io/bitbucket/pipelines/atlassian/adf-builder-javascript.svg)](https://bitbucket.org/atlassian/adf-builder-javascript/addon/pipelines/home#!/)
A library that simplifies building documents that follow the Atlassian Document Format structure.

@@ -33,3 +36,3 @@

.text(' ')
.emoji('smile');
.emoji(':smile:');
```

@@ -43,3 +46,3 @@

const doc = document`See the ${link('documentation', 'https://example.com')} ${emoji('smile')}`;
const doc = document`See the ${link('documentation', 'https://example.com')} ${emoji(':smile:')}`;
```

@@ -142,5 +145,1 @@

```
## Contributing
TBD

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc