@ddd-qc/agent-directory 6.5.0 → 6.7.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.
@@ -1 +1 @@
1
- {"version":3,"file":"agent_directory.fn.js","sourceRoot":"","sources":["../../src/bindings/agent_directory.fn.ts"],"names":[],"mappings":"AAAA,0DAA0D;AAK1D,2DAA2D;AAC3D,MAAM,CAAC,MAAM,2BAA2B,GAAmB;IAC1D,YAAY;IACZ,eAAe;IACf,cAAc;IAEd,uBAAuB;CACvB,CAAC;AAGF,iEAAiE;AACjE,MAAM,UAAU,wCAAwC,CAAC,QAAkB;IACxE,MAAM,GAAG,GAA+B,EAAE,CAAC;IAC3C,KAAK,MAAM,EAAE,IAAI,2BAA2B,EAAE;QAC3C,GAAG,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC,CAAC;KAC3B;IACD,OAAO,GAAG,CAAC;AACd,CAAC;AAGD,sFAAsF;AACtF,MAAM,CAAC,MAAM,2BAA2B,GAA+B,wCAAwC,CAAC,iBAAiB,CAAC,CAAC","sourcesContent":["/* This file is generated by zits. Do not edit manually */\n\nimport {ZomeName, FunctionName} from '@holochain/client';\n\n\n/** Array of all zome function names in \"agentDirectory\" */\nexport const agentDirectoryFunctionNames: FunctionName[] = [\n\t\"entry_defs\", \n\t\"get_zome_info\", \n\t\"get_dna_info\",\n\n\t\"get_registered_agents\",\n];\n\n\n/** Generate tuple array of function names with given zomeName */\nexport function generateAgentDirectoryZomeFunctionsArray(zomeName: ZomeName): [ZomeName, FunctionName][] {\n const fns: [ZomeName, FunctionName][] = [];\n for (const fn of agentDirectoryFunctionNames) {\n fns.push([zomeName, fn]);\n }\n return fns;\n}\n\n\n/** Tuple array of all zome function names with default zome name \"agent_directory\" */\nexport const agentDirectoryZomeFunctions: [ZomeName, FunctionName][] = generateAgentDirectoryZomeFunctionsArray(\"agent_directory\");\n"]}
1
+ {"version":3,"file":"agent_directory.fn.js","sourceRoot":"","sources":["../../src/bindings/agent_directory.fn.ts"],"names":[],"mappings":"AAAA,0DAA0D;AAK1D,2DAA2D;AAC3D,MAAM,CAAC,MAAM,2BAA2B,GAAmB;IAC1D,YAAY;IACZ,eAAe;IACf,cAAc;IACd,uBAAuB;CACvB,CAAC;AAGF,iEAAiE;AACjE,MAAM,UAAU,wCAAwC,CAAC,QAAkB;IACxE,MAAM,GAAG,GAA+B,EAAE,CAAC;IAC3C,KAAK,MAAM,EAAE,IAAI,2BAA2B,EAAE;QAC3C,GAAG,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC,CAAC;KAC3B;IACD,OAAO,GAAG,CAAC;AACd,CAAC;AAGD,sFAAsF;AACtF,MAAM,CAAC,MAAM,2BAA2B,GAA+B,wCAAwC,CAAC,iBAAiB,CAAC,CAAC","sourcesContent":["/* This file is generated by zits. Do not edit manually */\n\nimport {ZomeName, FunctionName} from '@holochain/client';\n\n\n/** Array of all zome function names in \"agentDirectory\" */\nexport const agentDirectoryFunctionNames: FunctionName[] = [\n\t\"entry_defs\", \n\t\"get_zome_info\", \n\t\"get_dna_info\",\n\t\"get_registered_agents\",\n];\n\n\n/** Generate tuple array of function names with given zomeName */\nexport function generateAgentDirectoryZomeFunctionsArray(zomeName: ZomeName): [ZomeName, FunctionName][] {\n const fns: [ZomeName, FunctionName][] = [];\n for (const fn of agentDirectoryFunctionNames) {\n fns.push([zomeName, fn]);\n }\n return fns;\n}\n\n\n/** Tuple array of all zome function names with default zome name \"agent_directory\" */\nexport const agentDirectoryZomeFunctions: [ZomeName, FunctionName][] = generateAgentDirectoryZomeFunctionsArray(\"agent_directory\");\n"]}
@@ -0,0 +1,7 @@
1
+ /** List of all Link kinds handled by this Zome */
2
+ export declare enum AgentDirectoryLinkType {
3
+ Agent = "Agent"
4
+ }
5
+ export declare enum AgentDirectoryUnitEnum {
6
+ Stub = "Stub"
7
+ }
@@ -0,0 +1,11 @@
1
+ /* This file is generated by zits. Do not edit manually */
2
+ /** List of all Link kinds handled by this Zome */
3
+ export var AgentDirectoryLinkType;
4
+ (function (AgentDirectoryLinkType) {
5
+ AgentDirectoryLinkType["Agent"] = "Agent";
6
+ })(AgentDirectoryLinkType || (AgentDirectoryLinkType = {}));
7
+ export var AgentDirectoryUnitEnum;
8
+ (function (AgentDirectoryUnitEnum) {
9
+ AgentDirectoryUnitEnum["Stub"] = "Stub";
10
+ })(AgentDirectoryUnitEnum || (AgentDirectoryUnitEnum = {}));
11
+ //# sourceMappingURL=agent_directory.integrity.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"agent_directory.integrity.js","sourceRoot":"","sources":["../../src/bindings/agent_directory.integrity.ts"],"names":[],"mappings":"AAAA,0DAA0D;AAG1D,kDAAkD;AAClD,MAAM,CAAN,IAAY,sBAEX;AAFD,WAAY,sBAAsB;IACjC,yCAAe,CAAA;AAChB,CAAC,EAFW,sBAAsB,KAAtB,sBAAsB,QAEjC;AACD,MAAM,CAAN,IAAY,sBAEX;AAFD,WAAY,sBAAsB;IACjC,uCAAa,CAAA;AACd,CAAC,EAFW,sBAAsB,KAAtB,sBAAsB,QAEjC","sourcesContent":["/* This file is generated by zits. Do not edit manually */\n\n\n/** List of all Link kinds handled by this Zome */\nexport enum AgentDirectoryLinkType {\n\tAgent = 'Agent',\n}\nexport enum AgentDirectoryUnitEnum {\n\tStub = 'Stub',\n}\n"]}
@@ -1,10 +1,13 @@
1
1
  import { AgentPubKey } from '@holochain/client';
2
2
  import { ZomeProxy } from '@ddd-qc/lit-happ';
3
+ import { AgentDirectoryUnitEnum, AgentDirectoryLinkType } from './agent_directory.integrity';
3
4
  /**
4
5
  *
5
6
  */
6
7
  export declare class AgentDirectoryProxy extends ZomeProxy {
7
8
  static readonly DEFAULT_ZOME_NAME = "agent_directory";
8
9
  static readonly FN_NAMES: string[];
10
+ static readonly ENTRY_TYPES: AgentDirectoryUnitEnum.Stub[];
11
+ static readonly LINK_TYPES: AgentDirectoryLinkType.Agent[];
9
12
  getRegisteredAgents(): Promise<AgentPubKey[]>;
10
13
  }
@@ -1,6 +1,7 @@
1
1
  /* This file is generated by zits. Do not edit manually */
2
2
  import { ZomeProxy } from '@ddd-qc/lit-happ';
3
3
  import { agentDirectoryFunctionNames } from './agent_directory.fn';
4
+ import { AgentDirectoryUnitEnum, AgentDirectoryLinkType } from './agent_directory.integrity';
4
5
  /**
5
6
  *
6
7
  */
@@ -11,4 +12,6 @@ export class AgentDirectoryProxy extends ZomeProxy {
11
12
  }
12
13
  AgentDirectoryProxy.DEFAULT_ZOME_NAME = "agent_directory";
13
14
  AgentDirectoryProxy.FN_NAMES = agentDirectoryFunctionNames;
15
+ AgentDirectoryProxy.ENTRY_TYPES = Object.values(AgentDirectoryUnitEnum);
16
+ AgentDirectoryProxy.LINK_TYPES = Object.values(AgentDirectoryLinkType);
14
17
  //# sourceMappingURL=agent_directory.proxy.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"agent_directory.proxy.js","sourceRoot":"","sources":["../../src/bindings/agent_directory.proxy.ts"],"names":[],"mappings":"AAAA,0DAA0D;AAoJ1D,OAAO,EAAC,SAAS,EAAC,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAC,2BAA2B,EAAC,MAAM,sBAAsB,CAAC;AAEjE;;GAEG;AACH,MAAM,OAAO,mBAAoB,SAAQ,SAAS;IAKhD,KAAK,CAAC,mBAAmB;QACvB,OAAO,IAAI,CAAC,IAAI,CAAC,uBAAuB,EAAE,IAAI,CAAC,CAAC;IAClD,CAAC;;AANe,qCAAiB,GAAG,iBAAiB,CAAA;AACrC,4BAAQ,GAAG,2BAA2B,CAAA","sourcesContent":["/* This file is generated by zits. Do not edit manually */\n\nimport {AGENT_DIRECTORY_PATH, AgentDirectoryEntry, Stub, } from './agent_directory.types';\nimport {\nWebsocketConnectionOptions,\n/** types.ts */\nHoloHash,\nAgentPubKey,\nDnaHash,\nWasmHash,\nEntryHash,\nActionHash,\nAnyDhtHash,\nExternalHash,\nKitsuneAgent,\nKitsuneSpace,\nHoloHashB64,\nAgentPubKeyB64,\nDnaHashB64,\nWasmHashB64,\nEntryHashB64,\nActionHashB64,\nAnyDhtHashB64,\nInstalledAppId,\nSignature,\nCellId,\nDnaProperties,\nRoleName,\nInstalledCell,\nTimestamp,\nDuration,\nHoloHashed,\nNetworkInfo,\nFetchPoolInfo,\n/** hdk/action.ts */\nSignedActionHashed,\nRegisterAgentActivity,\nActionHashed,\nActionType,\nAction,\nNewEntryAction,\nDna,\nAgentValidationPkg,\nInitZomesComplete,\nCreateLink,\nDeleteLink,\nOpenChain,\nCloseChain,\nUpdate,\nDelete,\nCreate,\n/** hdk/capabilities.ts */\nCapSecret,\nCapClaim,\nGrantedFunctionsType,\nGrantedFunctions,\nZomeCallCapGrant,\nCapAccessType,\nCapAccess,\nCapGrant,\n///** hdk/countersigning.ts */\n//CounterSigningSessionData,\n//PreflightRequest,\n//CounterSigningSessionTimes,\n//ActionBase,\n//CounterSigningAgents,\n//PreflightBytes,\n//Role,\n//CountersigningAgentState,\n/** hdk/dht-ops.ts */\nDhtOpType,\nDhtOp,\ngetDhtOpType,\ngetDhtOpAction,\ngetDhtOpEntry,\ngetDhtOpSignature,\n/** hdk/entry.ts */\nEntryVisibility,\nAppEntryDef,\nEntryType,\nEntryContent,\nEntry,\n/** hdk/record.ts */\nRecord as HcRecord,\nRecordEntry as HcRecordEntry,\n/** hdk/link.ts */\nAnyLinkableHash,\nZomeIndex,\nLinkType,\nLinkTag,\nRateWeight,\nRateBucketId,\nRateUnits,\nLink,\n/** api/admin/types.ts */\nInstalledAppInfoStatus,\nDeactivationReason,\nDisabledAppReason,\nStemCell,\nProvisionedCell,\nClonedCell,\nCellType,\nCellInfo,\nAppInfo,\nMembraneProof,\nFunctionName,\nZomeName,\nZomeDefinition,\nIntegrityZome,\nCoordinatorZome,\nDnaDefinition,\nResourceBytes,\nResourceMap,\nCellProvisioningStrategy,\nCellProvisioning,\nDnaVersionSpec,\nDnaVersionFlexible,\nAppRoleDnaManifest,\nAppRoleManifest,\nAppManifest,\nAppBundle,\nAppBundleSource,\nNetworkSeed,\nZomeLocation,\n } from '@holochain/client';\n\nimport {\n/** Common */\nDhtOpHashB64,\n//DnaHashB64, (duplicate)\n//AnyDhtHashB64, (duplicate)\nDhtOpHash,\n/** DnaFile */\nDnaFile,\nDnaDef,\nZomes,\nWasmCode,\n/** entry-details */\nEntryDetails,\nRecordDetails,\nDetails,\nDetailsType,\nEntryDhtStatus,\n/** Validation */\nValidationStatus,\nValidationReceipt,\n } from '@holochain-open-dev/core-types';\n\nimport {ZomeProxy} from '@ddd-qc/lit-happ';\nimport {agentDirectoryFunctionNames} from './agent_directory.fn';\n\n/**\n *\n */\nexport class AgentDirectoryProxy extends ZomeProxy {\n static readonly DEFAULT_ZOME_NAME = \"agent_directory\"\n static readonly FN_NAMES = agentDirectoryFunctionNames\n \n\n async getRegisteredAgents(): Promise<AgentPubKey[]> {\n return this.call('get_registered_agents', null);\n }\n\n}\n"]}
1
+ {"version":3,"file":"agent_directory.proxy.js","sourceRoot":"","sources":["../../src/bindings/agent_directory.proxy.ts"],"names":[],"mappings":"AAAA,0DAA0D;AAoJ1D,OAAO,EAAC,SAAS,EAAC,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAC,2BAA2B,EAAC,MAAM,sBAAsB,CAAC;AACjE,OAAO,EAAC,sBAAsB,EAAE,sBAAsB,EAAC,MAAM,6BAA6B,CAAC;AAE3F;;GAEG;AACH,MAAM,OAAO,mBAAoB,SAAQ,SAAS;IAMhD,KAAK,CAAC,mBAAmB;QACvB,OAAO,IAAI,CAAC,IAAI,CAAC,uBAAuB,EAAE,IAAI,CAAC,CAAC;IAClD,CAAC;;AAPe,qCAAiB,GAAG,iBAAiB,CAAC;AACtC,4BAAQ,GAAG,2BAA2B,CAAC;AACvC,+BAAW,GAAG,MAAM,CAAC,MAAM,CAAC,sBAAsB,CAAC,CAAC;AACpD,8BAAU,GAAG,MAAM,CAAC,MAAM,CAAC,sBAAsB,CAAC,CAAC","sourcesContent":["/* This file is generated by zits. Do not edit manually */\n\nimport {AGENT_DIRECTORY_PATH, AgentDirectoryEntry, Stub, } from './agent_directory.types';\nimport {\nWebsocketConnectionOptions,\n/** types.ts */\nHoloHash,\nAgentPubKey,\nDnaHash,\nWasmHash,\nEntryHash,\nActionHash,\nAnyDhtHash,\nExternalHash,\nKitsuneAgent,\nKitsuneSpace,\nHoloHashB64,\nAgentPubKeyB64,\nDnaHashB64,\nWasmHashB64,\nEntryHashB64,\nActionHashB64,\nAnyDhtHashB64,\nInstalledAppId,\nSignature,\nCellId,\nDnaProperties,\nRoleName,\nInstalledCell,\nTimestamp,\nDuration,\nHoloHashed,\nNetworkInfo,\nFetchPoolInfo,\n/** hdk/action.ts */\nSignedActionHashed,\nRegisterAgentActivity,\nActionHashed,\nActionType,\nAction,\nNewEntryAction,\nDna,\nAgentValidationPkg,\nInitZomesComplete,\nCreateLink,\nDeleteLink,\nOpenChain,\nCloseChain,\nUpdate,\nDelete,\nCreate,\n/** hdk/capabilities.ts */\nCapSecret,\nCapClaim,\nGrantedFunctionsType,\nGrantedFunctions,\nZomeCallCapGrant,\nCapAccessType,\nCapAccess,\nCapGrant,\n///** hdk/countersigning.ts */\n//CounterSigningSessionData,\n//PreflightRequest,\n//CounterSigningSessionTimes,\n//ActionBase,\n//CounterSigningAgents,\n//PreflightBytes,\n//Role,\n//CountersigningAgentState,\n/** hdk/dht-ops.ts */\nDhtOpType,\nDhtOp,\ngetDhtOpType,\ngetDhtOpAction,\ngetDhtOpEntry,\ngetDhtOpSignature,\n/** hdk/entry.ts */\nEntryVisibility,\nAppEntryDef,\nEntryType,\nEntryContent,\nEntry,\n/** hdk/record.ts */\nRecord as HcRecord,\nRecordEntry as HcRecordEntry,\n/** hdk/link.ts */\nAnyLinkableHash,\nZomeIndex,\nLinkType,\nLinkTag,\nRateWeight,\nRateBucketId,\nRateUnits,\nLink,\n/** api/admin/types.ts */\nInstalledAppInfoStatus,\nDeactivationReason,\nDisabledAppReason,\nStemCell,\nProvisionedCell,\nClonedCell,\nCellType,\nCellInfo,\nAppInfo,\nMembraneProof,\nFunctionName,\nZomeName,\nZomeDefinition,\nIntegrityZome,\nCoordinatorZome,\nDnaDefinition,\nResourceBytes,\nResourceMap,\nCellProvisioningStrategy,\nCellProvisioning,\nDnaVersionSpec,\nDnaVersionFlexible,\nAppRoleDnaManifest,\nAppRoleManifest,\nAppManifest,\nAppBundle,\nAppBundleSource,\nNetworkSeed,\nZomeLocation,\n } from '@holochain/client';\n\nimport {\n/** Common */\nDhtOpHashB64,\n//DnaHashB64, (duplicate)\n//AnyDhtHashB64, (duplicate)\nDhtOpHash,\n/** DnaFile */\nDnaFile,\nDnaDef,\nZomes,\nWasmCode,\n/** entry-details */\nEntryDetails,\nRecordDetails,\nDetails,\nDetailsType,\nEntryDhtStatus,\n/** Validation */\nValidationStatus,\nValidationReceipt,\n } from '@holochain-open-dev/core-types';\n\nimport {ZomeProxy} from '@ddd-qc/lit-happ';\nimport {agentDirectoryFunctionNames} from './agent_directory.fn';\nimport {AgentDirectoryUnitEnum, AgentDirectoryLinkType} from './agent_directory.integrity';\n\n/**\n *\n */\nexport class AgentDirectoryProxy extends ZomeProxy {\n static readonly DEFAULT_ZOME_NAME = \"agent_directory\";\n static readonly FN_NAMES = agentDirectoryFunctionNames;\n static readonly ENTRY_TYPES = Object.values(AgentDirectoryUnitEnum);\n static readonly LINK_TYPES = Object.values(AgentDirectoryLinkType);\n \n async getRegisteredAgents(): Promise<AgentPubKey[]> {\n return this.call('get_registered_agents', null);\n }\n}\n"]}
@@ -36,9 +36,9 @@ let AgentDirectoryList = class AgentDirectoryList extends ZomeElement {
36
36
  return html `<span>Loading...</span>`;
37
37
  }
38
38
  /* Agents */
39
- const agentLi = Object.entries(this.perspective.agents).map(([_index, agentIdB64]) => {
39
+ const agentLi = Object.entries(this.perspective.agents).map(([_index, agentId]) => {
40
40
  //console.log("" + index + ". " + agentIdB64)
41
- return html `<li value="${agentIdB64}">${agentIdB64}</li>`;
41
+ return html `<li value="${agentId.b64}">${agentId.short}</li>`;
42
42
  });
43
43
  /** render all */
44
44
  return html `
@@ -1 +1 @@
1
- {"version":3,"file":"agent-directory-list.js","sourceRoot":"","sources":["../../src/elements/agent-directory-list.ts"],"names":[],"mappings":";AAAA,OAAO,EAAC,IAAI,EAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EAAW,KAAK,EAAE,aAAa,EAAC,MAAM,mBAAmB,CAAC;AACjE,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAA4B,iBAAiB,EAAC,MAAM,wBAAwB,CAAC;AAEpF;;GAEG;AAEI,IAAM,kBAAkB,GAAxB,MAAM,kBAAmB,SAAQ,WAAyD;IAC/F,WAAW;IACX;QACE,KAAK,CAAC,iBAAiB,CAAC,iBAAiB,CAAC,CAAC;QAI7C,mBAAmB;QAEF,iBAAY,GAAG,KAAK,CAAC;IALtC,CAAC;IASD,oBAAoB;IAEpB,mCAAmC;IACnC,KAAK,CAAC,YAAY;QAChB,iDAAiD;QACjD,MAAM,IAAI,CAAC,OAAO,EAAE,CAAC;QACrB,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC;IAC3B,CAAC;IAGD,kCAAkC;IAClC,KAAK,CAAC,OAAO,CAAC,iBAAsB;QAClC,MAAM;IACR,CAAC;IAGD,MAAM;IACN,KAAK,CAAC,OAAO,CAAC,EAAQ;QACpB,iDAAiD;QACjD,MAAM,IAAI,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC;IAC7B,CAAC;IAGD,MAAM;IACN,MAAM;QACJ,OAAO,CAAC,GAAG,CAAC,qCAAqC,CAAC,CAAC;QAEnD,IAAI,CAAC,IAAI,CAAC,YAAY,EAAE;YACtB,OAAO,IAAI,CAAA,yBAAyB,CAAC;SACtC;QAED,YAAY;QACZ,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,GAAG,CACvD,CAAC,CAAC,MAAM,EAAE,UAAU,CAAC,EAAE,EAAE;YACvB,6CAA6C;YAC7C,OAAO,IAAI,CAAC,cAAc,UAAU,KAAK,UAAU,OAAO,CAAA;QAC5D,CAAC,CACJ,CAAA;QAED,iBAAiB;QACjB,OAAO,IAAI,CAAA;;YAEH,OAAO;;KAEd,CAAC;IACJ,CAAC;CACF,CAAA;AAlDkB;IAAhB,KAAK,EAAE;wDAA8B;AAT3B,kBAAkB;IAD9B,aAAa,CAAC,sBAAsB,CAAC;GACzB,kBAAkB,CA2D9B","sourcesContent":["import {html} from \"lit\";\nimport {property, state, customElement} from \"lit/decorators.js\";\nimport {ZomeElement} from \"@ddd-qc/lit-happ\";\nimport {AgentDirectoryPerspective, AgentDirectoryZvm} from \"../agent_directory.zvm\";\n\n/**\n * @element agent-directory-list\n */\n@customElement(\"agent-directory-list\")\nexport class AgentDirectoryList extends ZomeElement<AgentDirectoryPerspective, AgentDirectoryZvm> {\n /** Ctor */\n constructor() {\n super(AgentDirectoryZvm.DEFAULT_ZOME_NAME);\n }\n\n\n /** -- Fields -- */\n\n @state() private _initialized = false;\n\n\n\n /** -- Methods -- */\n\n /** After first call to render() */\n async firstUpdated() {\n //this._viewModel.subscribe(this, 'perspective');\n await this.refresh();\n this._initialized = true;\n }\n\n\n /** After each call to render() */\n async updated(changedProperties: any) {\n // n/a\n }\n\n\n /** */\n async refresh(_e?: any) {\n //console.log(\"refresh(): Pulling data from DHT\")\n await this._zvm.probeAll();\n }\n\n\n /** */\n render() {\n console.log(\"agent-directory-list render() START\");\n\n if (!this._initialized) {\n return html`<span>Loading...</span>`;\n }\n\n /* Agents */\n const agentLi = Object.entries(this.perspective.agents).map(\n ([_index, agentIdB64]) => {\n //console.log(\"\" + index + \". \" + agentIdB64)\n return html `<li value=\"${agentIdB64}\">${agentIdB64}</li>`\n }\n )\n\n /** render all */\n return html` \n <ul>\n ${agentLi}\n </ul>\n `;\n }\n}\n"]}
1
+ {"version":3,"file":"agent-directory-list.js","sourceRoot":"","sources":["../../src/elements/agent-directory-list.ts"],"names":[],"mappings":";AAAA,OAAO,EAAC,IAAI,EAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EAAW,KAAK,EAAE,aAAa,EAAC,MAAM,mBAAmB,CAAC;AACjE,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAA4B,iBAAiB,EAAC,MAAM,wBAAwB,CAAC;AAEpF;;GAEG;AAEI,IAAM,kBAAkB,GAAxB,MAAM,kBAAmB,SAAQ,WAAyD;IAC/F,WAAW;IACX;QACE,KAAK,CAAC,iBAAiB,CAAC,iBAAiB,CAAC,CAAC;QAI7C,mBAAmB;QAEF,iBAAY,GAAG,KAAK,CAAC;IALtC,CAAC;IASD,oBAAoB;IAEpB,mCAAmC;IACnC,KAAK,CAAC,YAAY;QAChB,iDAAiD;QACjD,MAAM,IAAI,CAAC,OAAO,EAAE,CAAC;QACrB,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC;IAC3B,CAAC;IAGD,kCAAkC;IAClC,KAAK,CAAC,OAAO,CAAC,iBAAsB;QAClC,MAAM;IACR,CAAC;IAGD,MAAM;IACN,KAAK,CAAC,OAAO,CAAC,EAAQ;QACpB,iDAAiD;QACjD,MAAM,IAAI,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC;IAC7B,CAAC;IAGD,MAAM;IACN,MAAM;QACJ,OAAO,CAAC,GAAG,CAAC,qCAAqC,CAAC,CAAC;QAEnD,IAAI,CAAC,IAAI,CAAC,YAAY,EAAE;YACtB,OAAO,IAAI,CAAA,yBAAyB,CAAC;SACtC;QAED,YAAY;QACZ,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,GAAG,CACvD,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,EAAE;YACpB,6CAA6C;YAC7C,OAAO,IAAI,CAAC,cAAc,OAAO,CAAC,GAAG,KAAK,OAAO,CAAC,KAAK,OAAO,CAAA;QAChE,CAAC,CACJ,CAAA;QAED,iBAAiB;QACjB,OAAO,IAAI,CAAA;;YAEH,OAAO;;KAEd,CAAC;IACJ,CAAC;CACF,CAAA;AAlDkB;IAAhB,KAAK,EAAE;wDAA8B;AAT3B,kBAAkB;IAD9B,aAAa,CAAC,sBAAsB,CAAC;GACzB,kBAAkB,CA2D9B","sourcesContent":["import {html} from \"lit\";\nimport {property, state, customElement} from \"lit/decorators.js\";\nimport {ZomeElement} from \"@ddd-qc/lit-happ\";\nimport {AgentDirectoryPerspective, AgentDirectoryZvm} from \"../agent_directory.zvm\";\n\n/**\n * @element agent-directory-list\n */\n@customElement(\"agent-directory-list\")\nexport class AgentDirectoryList extends ZomeElement<AgentDirectoryPerspective, AgentDirectoryZvm> {\n /** Ctor */\n constructor() {\n super(AgentDirectoryZvm.DEFAULT_ZOME_NAME);\n }\n\n\n /** -- Fields -- */\n\n @state() private _initialized = false;\n\n\n\n /** -- Methods -- */\n\n /** After first call to render() */\n async firstUpdated() {\n //this._viewModel.subscribe(this, 'perspective');\n await this.refresh();\n this._initialized = true;\n }\n\n\n /** After each call to render() */\n async updated(changedProperties: any) {\n // n/a\n }\n\n\n /** */\n async refresh(_e?: any) {\n //console.log(\"refresh(): Pulling data from DHT\")\n await this._zvm.probeAll();\n }\n\n\n /** */\n render() {\n console.log(\"agent-directory-list render() START\");\n\n if (!this._initialized) {\n return html`<span>Loading...</span>`;\n }\n\n /* Agents */\n const agentLi = Object.entries(this.perspective.agents).map(\n ([_index, agentId]) => {\n //console.log(\"\" + index + \". \" + agentIdB64)\n return html `<li value=\"${agentId.b64}\">${agentId.short}</li>`\n }\n )\n\n /** render all */\n return html` \n <ul>\n ${agentLi}\n </ul>\n `;\n }\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ddd-qc/agent-directory",
3
- "version": "6.5.0",
3
+ "version": "6.7.0",
4
4
  "license" : "CAL-1.0",
5
5
  "keywords": ["holochain", "zome"],
6
6
  "main": "./dist/index.js",