// Footprint node and Model node ID
const footprintID = "145d8c8c-f36c-4f21-8a93-61effdd5235f.defaultFootprint";
const modelID = "3f1159e9-ce33-47a0-8803-c447a430a9c3";
// Declare specific footprint and model node based on their ID as a PcbLayoutNode
const footprintNode = flux.getNodeById(footprintID) as PcbLayoutNode;
const modelNode = flux.getNodeById(modelID) as PcbLayoutNode;
// This will sort and return an array of all available assets in the project with file type .kicad_mod
const footprintAssetNotSorted = flux.assets.filter((asset) => asset.fileType === "kicad_mod").map((asset) => asset.name);
const footprintAssetId = footprintAssetNotSorted.sort();
// This will sort and return an array of all available assets in the project with file type .step
const modelAssetIdNotSorted = flux.assets.filter((asset) => asset.fileType === "step").map((asset) => asset.name);
const modelAssetId = modelAssetIdNotSorted.sort();
// This checks if footprint and model node has Asset rule
if (footprintNode || modelNode) {
const assetFootprintRule = footprintNode.rules.find((rule) => rule.key === "asset");
const assetModelRule = modelNode.rules.find((rule) => rule.key === "asset");
// First, look for property that is named "Package", then use its value to