@lunnoa/client 0.0.0-development → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +202 -202
- package/README.md +372 -338
- package/dist/cli.js +31 -1
- package/dist/index.cjs +31 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +703 -585
- package/dist/index.d.ts +703 -585
- package/dist/index.js +31 -1
- package/dist/index.js.map +1 -1
- package/dist/react.cjs +31 -1
- package/dist/react.cjs.map +1 -1
- package/dist/react.d.cts +780 -719
- package/dist/react.d.ts +780 -719
- package/dist/react.js +31 -1
- package/dist/react.js.map +1 -1
- package/package.json +7 -5
- package/skills/lunnoa-client/SKILL.md +517 -0
- package/skills/lunnoa-solution-design/SKILL.md +190 -0
package/dist/cli.js
CHANGED
|
@@ -1506,12 +1506,42 @@ var QueueItemsResource = class {
|
|
|
1506
1506
|
`/api/queues/${queueId}/items/${itemId}`
|
|
1507
1507
|
);
|
|
1508
1508
|
}
|
|
1509
|
-
/** Adds an item to a queue. */
|
|
1509
|
+
/** Adds an item to a queue. Pass `objectId` to link the item to an entity. */
|
|
1510
1510
|
create(queueId, data) {
|
|
1511
1511
|
return this.http.post(`/api/queues/${queueId}/items`, {
|
|
1512
1512
|
body: data
|
|
1513
1513
|
});
|
|
1514
1514
|
}
|
|
1515
|
+
/**
|
|
1516
|
+
* Lists queue items linked to an Object across all queues in the workspace.
|
|
1517
|
+
* Use for Object detail "Work" panels.
|
|
1518
|
+
*/
|
|
1519
|
+
listByObject(objectId, options = {}) {
|
|
1520
|
+
return this.http.get(
|
|
1521
|
+
`/api/objects/${objectId}/queue-items`,
|
|
1522
|
+
{
|
|
1523
|
+
query: {
|
|
1524
|
+
status: options.status,
|
|
1525
|
+
limit: options.limit,
|
|
1526
|
+
offset: options.offset,
|
|
1527
|
+
expansion: serializeCsv(options.expansion)
|
|
1528
|
+
}
|
|
1529
|
+
}
|
|
1530
|
+
);
|
|
1531
|
+
}
|
|
1532
|
+
/** Async-iterates every queue item linked to an Object. */
|
|
1533
|
+
iterateByObject(objectId, options = {}) {
|
|
1534
|
+
return iterateOffset(async (offset) => {
|
|
1535
|
+
const result = await this.listByObject(objectId, {
|
|
1536
|
+
...options,
|
|
1537
|
+
offset
|
|
1538
|
+
});
|
|
1539
|
+
return {
|
|
1540
|
+
items: result.items ?? [],
|
|
1541
|
+
pagination: result.pagination
|
|
1542
|
+
};
|
|
1543
|
+
});
|
|
1544
|
+
}
|
|
1515
1545
|
/** Adds many items to a queue in one call. */
|
|
1516
1546
|
bulkCreate(queueId, data) {
|
|
1517
1547
|
return this.http.post(
|
package/dist/index.cjs
CHANGED
|
@@ -1535,12 +1535,42 @@ var QueueItemsResource = class {
|
|
|
1535
1535
|
`/api/queues/${queueId}/items/${itemId}`
|
|
1536
1536
|
);
|
|
1537
1537
|
}
|
|
1538
|
-
/** Adds an item to a queue. */
|
|
1538
|
+
/** Adds an item to a queue. Pass `objectId` to link the item to an entity. */
|
|
1539
1539
|
create(queueId, data) {
|
|
1540
1540
|
return this.http.post(`/api/queues/${queueId}/items`, {
|
|
1541
1541
|
body: data
|
|
1542
1542
|
});
|
|
1543
1543
|
}
|
|
1544
|
+
/**
|
|
1545
|
+
* Lists queue items linked to an Object across all queues in the workspace.
|
|
1546
|
+
* Use for Object detail "Work" panels.
|
|
1547
|
+
*/
|
|
1548
|
+
listByObject(objectId, options = {}) {
|
|
1549
|
+
return this.http.get(
|
|
1550
|
+
`/api/objects/${objectId}/queue-items`,
|
|
1551
|
+
{
|
|
1552
|
+
query: {
|
|
1553
|
+
status: options.status,
|
|
1554
|
+
limit: options.limit,
|
|
1555
|
+
offset: options.offset,
|
|
1556
|
+
expansion: serializeCsv(options.expansion)
|
|
1557
|
+
}
|
|
1558
|
+
}
|
|
1559
|
+
);
|
|
1560
|
+
}
|
|
1561
|
+
/** Async-iterates every queue item linked to an Object. */
|
|
1562
|
+
iterateByObject(objectId, options = {}) {
|
|
1563
|
+
return iterateOffset(async (offset) => {
|
|
1564
|
+
const result = await this.listByObject(objectId, {
|
|
1565
|
+
...options,
|
|
1566
|
+
offset
|
|
1567
|
+
});
|
|
1568
|
+
return {
|
|
1569
|
+
items: result.items ?? [],
|
|
1570
|
+
pagination: result.pagination
|
|
1571
|
+
};
|
|
1572
|
+
});
|
|
1573
|
+
}
|
|
1544
1574
|
/** Adds many items to a queue in one call. */
|
|
1545
1575
|
bulkCreate(queueId, data) {
|
|
1546
1576
|
return this.http.post(
|