@timeax/service-builder 0.1.1 → 0.1.3
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/dist/index.js +55 -21
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -10084,6 +10084,7 @@ var Panel = React27.forwardRef(function Panel2({
|
|
|
10084
10084
|
width: size.width != null ? `${size.width}px` : void 0,
|
|
10085
10085
|
height: size.height != null ? `${size.height}px` : void 0
|
|
10086
10086
|
};
|
|
10087
|
+
const panelWidth = size.width != null ? `${size.width}px` : panelRef.current ? `${Math.round(panelRef.current.getBoundingClientRect().width)}px` : void 0;
|
|
10087
10088
|
const offsetStyle = maintainPosition ? {
|
|
10088
10089
|
...offsets.left != null ? { left: `${offsets.left}px` } : null,
|
|
10089
10090
|
...offsets.top != null ? { top: `${offsets.top}px` } : null,
|
|
@@ -10102,6 +10103,8 @@ var Panel = React27.forwardRef(function Panel2({
|
|
|
10102
10103
|
...sizeStyle,
|
|
10103
10104
|
...offsetStyle,
|
|
10104
10105
|
...edgeStrokeStyle,
|
|
10106
|
+
// expose custom property for children
|
|
10107
|
+
["--panel-width"]: panelWidth,
|
|
10105
10108
|
touchAction: resizable ? "none" : void 0,
|
|
10106
10109
|
cursor: resizable ? cursor : void 0
|
|
10107
10110
|
},
|
|
@@ -11286,7 +11289,7 @@ function IncludesList({ className, children }) {
|
|
|
11286
11289
|
function IncludesItem({ title, badge, actions, className }) {
|
|
11287
11290
|
return /* @__PURE__ */ jsxs33("div", { className: cn("flex items-center justify-between rounded-md p-2", "bg-gray-50 dark:bg-gray-800/50", className), children: [
|
|
11288
11291
|
/* @__PURE__ */ jsxs33("div", { className: "flex min-w-0 items-center gap-2", children: [
|
|
11289
|
-
/* @__PURE__ */ jsx50("span", { className: "truncate text-sm text-gray-800 dark:text-gray-200", children: title }),
|
|
11292
|
+
/* @__PURE__ */ jsx50("span", { title, className: "max-w-[calc(var(--panel-width)-11rem)] truncate text-sm text-gray-800 dark:text-gray-200", children: title }),
|
|
11290
11293
|
badge
|
|
11291
11294
|
] }),
|
|
11292
11295
|
!!actions?.length && /* @__PURE__ */ jsx50("div", { className: "flex items-center gap-2", children: actions.map((a, idx) => /* @__PURE__ */ jsx50(IncludesIconAction, { ...a }, idx)) })
|
|
@@ -15725,14 +15728,7 @@ import { FiEdit2, FiFilter as FiFilter2, FiFolderPlus, FiPlus as FiPlus2, FiTras
|
|
|
15725
15728
|
|
|
15726
15729
|
// src/workspace/bottom-panel/service-detail-card.tsx
|
|
15727
15730
|
import { jsx as jsx78, jsxs as jsxs56 } from "react/jsx-runtime";
|
|
15728
|
-
function ServiceDetailCard({
|
|
15729
|
-
mode,
|
|
15730
|
-
row,
|
|
15731
|
-
snapshot,
|
|
15732
|
-
onNodeClick,
|
|
15733
|
-
onOpenFallbackQuickAdd,
|
|
15734
|
-
onOpenFallbackEditor
|
|
15735
|
-
}) {
|
|
15731
|
+
function ServiceDetailCard({ mode, row, snapshot, onNodeClick, onOpenFallbackQuickAdd, onOpenFallbackEditor }) {
|
|
15736
15732
|
const summary = row.summary;
|
|
15737
15733
|
const service = row.service;
|
|
15738
15734
|
return /* @__PURE__ */ jsxs56("div", { className: "space-y-5", children: [
|
|
@@ -15741,13 +15737,12 @@ function ServiceDetailCard({
|
|
|
15741
15737
|
/* @__PURE__ */ jsxs56("div", { className: "min-w-0", children: [
|
|
15742
15738
|
/* @__PURE__ */ jsxs56("div", { className: "flex items-center gap-2", children: [
|
|
15743
15739
|
/* @__PURE__ */ jsx78(StatusDot, { tone: row.statusTone, className: "mt-0.5" }),
|
|
15744
|
-
/* @__PURE__ */ jsx78("h5", { className: "truncate text-lg font-semibold text-slate-900 dark:text-slate-100", children: summary.name })
|
|
15745
|
-
] }),
|
|
15746
|
-
/* @__PURE__ */ jsxs56("div", { className: "mt-2 flex flex-wrap gap-2 text-xs text-slate-500 dark:text-slate-400", children: [
|
|
15747
15740
|
/* @__PURE__ */ jsxs56("span", { children: [
|
|
15748
15741
|
"#",
|
|
15749
15742
|
summary.id
|
|
15750
|
-
] })
|
|
15743
|
+
] })
|
|
15744
|
+
] }),
|
|
15745
|
+
/* @__PURE__ */ jsxs56("div", { className: "mt-2 flex flex-wrap gap-2 text-xs text-slate-500 dark:text-slate-400", children: [
|
|
15751
15746
|
summary.category ? /* @__PURE__ */ jsx78("span", { children: summary.category }) : null,
|
|
15752
15747
|
summary.platformId ? /* @__PURE__ */ jsx78("span", { children: summary.platformId }) : null
|
|
15753
15748
|
] })
|
|
@@ -15792,8 +15787,20 @@ function ServiceDetailCard({
|
|
|
15792
15787
|
),
|
|
15793
15788
|
/* @__PURE__ */ jsxs56("div", { className: "rounded-2xl border border-slate-200 bg-white p-4 dark:border-slate-800 dark:bg-slate-950/80", children: [
|
|
15794
15789
|
/* @__PURE__ */ jsxs56("div", { className: "flex flex-wrap gap-2", children: [
|
|
15795
|
-
/* @__PURE__ */ jsx78(
|
|
15796
|
-
|
|
15790
|
+
/* @__PURE__ */ jsx78(
|
|
15791
|
+
FilterChip,
|
|
15792
|
+
{
|
|
15793
|
+
label: row.check?.fitsConstraints ? "Constraints fit" : "Constraint mismatch",
|
|
15794
|
+
tone: row.check?.fitsConstraints ? "success" : "danger"
|
|
15795
|
+
}
|
|
15796
|
+
),
|
|
15797
|
+
/* @__PURE__ */ jsx78(
|
|
15798
|
+
FilterChip,
|
|
15799
|
+
{
|
|
15800
|
+
label: row.check?.passesRate ? "Rate ok" : "Rate blocked",
|
|
15801
|
+
tone: row.check?.passesRate ? "success" : "warning"
|
|
15802
|
+
}
|
|
15803
|
+
),
|
|
15797
15804
|
/* @__PURE__ */ jsx78(
|
|
15798
15805
|
FilterChip,
|
|
15799
15806
|
{
|
|
@@ -15802,18 +15809,45 @@ function ServiceDetailCard({
|
|
|
15802
15809
|
}
|
|
15803
15810
|
)
|
|
15804
15811
|
] }),
|
|
15805
|
-
row.reasonLabels.length ? /* @__PURE__ */ jsx78("div", { className: "mt-3 flex flex-wrap gap-2", children: row.reasonLabels.map((reason) => /* @__PURE__ */ jsx78(
|
|
15812
|
+
row.reasonLabels.length ? /* @__PURE__ */ jsx78("div", { className: "mt-3 flex flex-wrap gap-2", children: row.reasonLabels.map((reason) => /* @__PURE__ */ jsx78(
|
|
15813
|
+
"span",
|
|
15814
|
+
{
|
|
15815
|
+
className: "rounded-full bg-amber-50 px-2.5 py-1 text-xs text-amber-700 dark:bg-amber-500/10 dark:text-amber-200",
|
|
15816
|
+
children: reason
|
|
15817
|
+
},
|
|
15818
|
+
`${row.id}:${reason}`
|
|
15819
|
+
)) }) : /* @__PURE__ */ jsx78("p", { className: "mt-3 text-sm text-slate-500 dark:text-slate-400", children: "This service is a clean fit for the current visible-group and selected-trigger context." })
|
|
15806
15820
|
] })
|
|
15807
15821
|
] }) : null,
|
|
15808
15822
|
/* @__PURE__ */ jsxs56("section", { className: "space-y-3", children: [
|
|
15809
15823
|
/* @__PURE__ */ jsx78(SectionTitle2, { title: "Capabilities", description: "Flags and pricing hints attached to this service." }),
|
|
15810
15824
|
/* @__PURE__ */ jsx78("div", { className: "rounded-2xl border border-slate-200 bg-white p-4 dark:border-slate-800 dark:bg-slate-950/80", children: summary.flags.length || service?.meta ? /* @__PURE__ */ jsxs56("div", { className: "flex flex-wrap gap-2", children: [
|
|
15811
|
-
summary.flags.map((flag) => /* @__PURE__ */ jsx78(
|
|
15812
|
-
|
|
15825
|
+
summary.flags.map((flag) => /* @__PURE__ */ jsx78(
|
|
15826
|
+
"span",
|
|
15827
|
+
{
|
|
15828
|
+
className: "rounded-full bg-emerald-50 px-2.5 py-1 text-xs text-emerald-700 dark:bg-emerald-500/10 dark:text-emerald-200",
|
|
15829
|
+
children: flag
|
|
15830
|
+
},
|
|
15831
|
+
flag
|
|
15832
|
+
)),
|
|
15833
|
+
Object.keys(service?.meta ?? {}).slice(0, 3).map((key) => /* @__PURE__ */ jsx78(
|
|
15834
|
+
"span",
|
|
15835
|
+
{
|
|
15836
|
+
className: "rounded-full bg-slate-100 px-2.5 py-1 text-xs text-slate-600 dark:bg-slate-900 dark:text-slate-300",
|
|
15837
|
+
children: key
|
|
15838
|
+
},
|
|
15839
|
+
key
|
|
15840
|
+
))
|
|
15813
15841
|
] }) : /* @__PURE__ */ jsx78("p", { className: "text-sm text-slate-500 dark:text-slate-400", children: "No capability flags were published for this service." }) })
|
|
15814
15842
|
] }),
|
|
15815
15843
|
/* @__PURE__ */ jsxs56("section", { className: "space-y-3", children: [
|
|
15816
|
-
/* @__PURE__ */ jsx78(
|
|
15844
|
+
/* @__PURE__ */ jsx78(
|
|
15845
|
+
SectionTitle2,
|
|
15846
|
+
{
|
|
15847
|
+
title: "Bindings",
|
|
15848
|
+
description: "Nodes currently connected to this service. Click any node to jump back into the canvas."
|
|
15849
|
+
}
|
|
15850
|
+
),
|
|
15817
15851
|
/* @__PURE__ */ jsx78("div", { className: "rounded-2xl border border-slate-200 bg-white p-4 dark:border-slate-800 dark:bg-slate-950/80", children: summary.attachedNodeIds.length ? /* @__PURE__ */ jsx78("div", { className: "flex flex-wrap gap-2", children: summary.attachedNodeIds.map((nodeId, index) => /* @__PURE__ */ jsx78(
|
|
15818
15852
|
"button",
|
|
15819
15853
|
{
|
|
@@ -15835,7 +15869,7 @@ function SectionTitle2({ title, description }) {
|
|
|
15835
15869
|
}
|
|
15836
15870
|
function DetailMetric({ label, value }) {
|
|
15837
15871
|
return /* @__PURE__ */ jsxs56("div", { className: "rounded-2xl bg-white px-4 py-3 dark:bg-slate-950", children: [
|
|
15838
|
-
/* @__PURE__ */ jsx78("p", { className: "text-[11px] font-semibold
|
|
15872
|
+
/* @__PURE__ */ jsx78("p", { className: "text-[11px] font-semibold tracking-[0.16em] text-slate-400 uppercase dark:text-slate-500", children: label }),
|
|
15839
15873
|
/* @__PURE__ */ jsx78("p", { className: "mt-2 text-sm font-semibold text-slate-900 dark:text-slate-100", children: value })
|
|
15840
15874
|
] });
|
|
15841
15875
|
}
|
|
@@ -17453,7 +17487,7 @@ var policiesByBranch = {
|
|
|
17453
17487
|
var services = {
|
|
17454
17488
|
1001: {
|
|
17455
17489
|
id: 1001,
|
|
17456
|
-
name: "Instagram Followers \u2022 Fast",
|
|
17490
|
+
name: "Instagram Followers this shidshjs dcsh sojf dso sodhs jhdv sdh vshfdv sohfdv sohfs fhso fhsof sihfi \u2022 Fast",
|
|
17457
17491
|
rate: 1.25,
|
|
17458
17492
|
min: 50,
|
|
17459
17493
|
max: 5e4,
|