poi-plugin-remodel-assistant 1.0.1065-beta → 1.0.1069-beta

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/assets/main.css CHANGED
@@ -10808,7 +10808,7 @@ body.decision-modal-is-dragging * {
10808
10808
  /* 1.0.1065: Today list uses one stable visual grid. Two tag slots are reserved
10809
10809
  * even when empty so icon/name alignment never changes with row state. */
10810
10810
  #item-improvement .decision-equipment-row.is-workbench {
10811
- grid-template-columns: 42px 76px minmax(0, 1fr);
10811
+ grid-template-columns: 42px minmax(0, 1fr) 76px;
10812
10812
  column-gap: 10px;
10813
10813
  align-items: center;
10814
10814
  height: 64px;
@@ -10825,7 +10825,7 @@ body.decision-modal-is-dragging * {
10825
10825
  #item-improvement .decision-equipment-row.is-workbench .decision-workbench-tag-column {
10826
10826
  display: flex;
10827
10827
  flex-direction: column;
10828
- align-items: flex-start;
10828
+ align-items: flex-end;
10829
10829
  justify-content: center;
10830
10830
  gap: 3px;
10831
10831
  width: 76px;
@@ -10910,6 +10910,12 @@ body.decision-modal-is-dragging * {
10910
10910
  font-weight: 700;
10911
10911
  }
10912
10912
 
10913
+ #item-improvement .decision-detail-related-plan-parent {
10914
+ color: #a9b7bf;
10915
+ font-size: var(--improvement-font-small);
10916
+ font-weight: 600;
10917
+ }
10918
+
10913
10919
  #item-improvement .decision-detail-related-plan strong {
10914
10920
  font-size: var(--improvement-font-small);
10915
10921
  font-weight: 700;
@@ -10925,3 +10931,15 @@ body.decision-modal-is-dragging * {
10925
10931
  margin-left: 137px;
10926
10932
  }
10927
10933
  }
10934
+
10935
+ /* 1.0.1069: an unowned Acquisition Current Start is actionable Today work.
10936
+ * Keep source facts prominent while deferring improvement-only assistant/date/cost
10937
+ * sections until the equipment actually enters live inventory. */
10938
+ #item-improvement .decision-workbench-acquisition-source-list {
10939
+ margin: 6px 0 0;
10940
+ padding-left: 18px;
10941
+ }
10942
+
10943
+ #item-improvement .decision-workbench-acquisition-source-list li + li {
10944
+ margin-top: 3px;
10945
+ }
package/i18n/en-US.json CHANGED
@@ -370,6 +370,7 @@
370
370
  "equipment.Plan management": "Plan management",
371
371
  "equipment.Consumable plan": "Consumable plan",
372
372
  "equipment.Materials insufficient": "Materials insufficient",
373
+ "equipment.Acquire first": "Acquire first",
373
374
  "equipment.Clear": "Clear",
374
375
  "equipment.Clear filters": "Clear filters",
375
376
  "equipment.Completed": "Completed",
@@ -933,12 +934,17 @@
933
934
  "shared.System-recommended improvement starting point": "System-recommended improvement starting point",
934
935
  "shared.Select a valid route before the system can recommend a starting point": "Select a valid route before the system can recommend a starting point",
935
936
  "shared.Corresponding plan target": "Corresponding Plan target",
937
+ "shared.Current plan target": "Current Plan target",
938
+ "shared.For plan": "for",
936
939
  "shared.Related plans": "Related plans",
937
940
  "shared.Consumable plan": "Consumable plan",
938
941
  "workbench.Plan targets": "Plan targets",
939
942
  "workbench.Plan targets available for improvement on selected day": "Today improvable",
940
- "workbench.No plan target is available for improvement on selected day": "No unfinished Plan target is available for improvement on the selected day",
943
+ "workbench.No plan target is available for improvement on selected day": "No unfinished Plan target needs action on the selected day",
941
944
  "app.Left shows Plan targets that satisfy the selected day's improvement conditions.": "Left shows Plan targets that satisfy the selected day's improvement conditions.",
945
+ "app.Review Current Plan actions today": "Review Current Plan actions today",
946
+ "app.Left shows the next Current Plan action, including acquisition before improvement.": "Left shows the next Current Plan action, including acquisition before improvement.",
947
+ "app.Right shows the selected Current Start; low-cost acquisition and equipment-conversion Alternatives remain user-selectable.": "Right shows the selected Current Start; low-cost acquisition and equipment-conversion Alternatives remain user-selectable.",
942
948
  "data.Data management": "Data management",
943
949
  "data.Export plans, route choices, and interface settings to a data file": "Export improvement plans, route choices, and interface settings.",
944
950
  "data.Import plans, route choices, and interface settings from a data file": "Import improvement plans, route choices, and interface settings from a data file.",
@@ -955,7 +961,7 @@
955
961
  "equipment.Search and sort": "Search and sort",
956
962
  "workbench.Clear filters": "Clear filters",
957
963
  "workbench.Display scope": "Display scope",
958
- "workbench.Today improvable": "Today improvable",
964
+ "workbench.Today improvable": "Today actions",
959
965
  "equipment.Plan %d": "Plan %d",
960
966
  "workbench.Available dates": "Available dates",
961
967
  "workbench.Expected materials for this upgrade": "Expected materials for this upgrade",
@@ -969,6 +975,11 @@
969
975
  "workbench.Improvement source": "Improvement source",
970
976
  "workbench.Periodic quest": "Periodic quest",
971
977
  "workbench.Ship source": "Ship source",
978
+ "workbench.Acquire Current start": "Acquire Current start",
979
+ "workbench.Obtain this Current start before improvement": "Obtain this Current start before improvement",
980
+ "workbench.The selected Current start is not owned yet; acquire it first, then continue the selected route.": "The selected Current start is not owned yet; acquire it first, then continue the selected route.",
981
+ "workbench.Ship remodel at Lv.%d": "Ship remodel at Lv.%d",
982
+ "workbench.Ship initial equipment": "Ship initial equipment",
972
983
  "workbench.Sources": "Sources",
973
984
  "workbench.No known source": "No known source",
974
985
  "workbench.Search sources": "Search sources",
package/i18n/ja-JP.json CHANGED
@@ -370,6 +370,7 @@
370
370
  "equipment.Plan management": "計画管理",
371
371
  "equipment.Consumable plan": "消耗材計画",
372
372
  "equipment.Materials insufficient": "資材不足",
373
+ "equipment.Acquire first": "先に入手",
373
374
  "equipment.Clear": "解除",
374
375
  "equipment.Clear filters": "条件をクリア",
375
376
  "equipment.Completed": "完了",
@@ -933,12 +934,17 @@
933
934
  "shared.System-recommended improvement starting point": "システム推奨の改修開始装備",
934
935
  "shared.Select a valid route before the system can recommend a starting point": "有効なルートを選択すると、システムが改修開始装備を推奨できます",
935
936
  "shared.Corresponding plan target": "対応する計画目標",
937
+ "shared.Current plan target": "現在の計画目標",
938
+ "shared.For plan": "使用先",
936
939
  "shared.Related plans": "関連計画",
937
940
  "shared.Consumable plan": "消耗材計画",
938
941
  "workbench.Plan targets": "計画目標",
939
942
  "workbench.Plan targets available for improvement on selected day": "今日改修可",
940
- "workbench.No plan target is available for improvement on selected day": "選択した曜日に改修できる未完了の計画目標はありません",
943
+ "workbench.No plan target is available for improvement on selected day": "選択した曜日に対応が必要な未完了計画はありません",
941
944
  "app.Left shows Plan targets that satisfy the selected day's improvement conditions.": "左側には選択した曜日の改修条件を満たす計画目標を表示します。",
945
+ "app.Review Current Plan actions today": "今日の Current Plan 行動を確認",
946
+ "app.Left shows the next Current Plan action, including acquisition before improvement.": "左側には、改修前の装備入手を含む Current Plan の次の行動を表示します。",
947
+ "app.Right shows the selected Current Start; low-cost acquisition and equipment-conversion Alternatives remain user-selectable.": "右側には選択した Current Start を表示し、低コスト入手と装備更新の Alternative はどちらも選択肢として残します。",
942
948
  "data.Data management": "データ管理",
943
949
  "data.Export plans, route choices, and interface settings to a data file": "改修計画、ルート選択、画面設定を書き出します。",
944
950
  "data.Import plans, route choices, and interface settings from a data file": "データファイルから改修計画、ルート選択、画面設定を読み込みます。",
@@ -955,7 +961,7 @@
955
961
  "equipment.Search and sort": "検索と並び替え",
956
962
  "workbench.Clear filters": "フィルターをクリア",
957
963
  "workbench.Display scope": "表示範囲",
958
- "workbench.Today improvable": "本日改修可",
964
+ "workbench.Today improvable": "今日やること",
959
965
  "equipment.Plan %d": "計画 %d",
960
966
  "workbench.Available dates": "改修可能日",
961
967
  "workbench.Expected materials for this upgrade": "今回の改修期待資材",
@@ -969,6 +975,11 @@
969
975
  "workbench.Improvement source": "改修入手元",
970
976
  "workbench.Periodic quest": "定期任務",
971
977
  "workbench.Ship source": "艦娘入手元",
978
+ "workbench.Acquire Current start": "Current 起点を入手",
979
+ "workbench.Obtain this Current start before improvement": "改修前にこの Current 起点を入手",
980
+ "workbench.The selected Current start is not owned yet; acquire it first, then continue the selected route.": "選択した Current 起点は未所持です。先に入手してから、選択済みルートを続行します。",
981
+ "workbench.Ship remodel at Lv.%d": "Lv.%d で艦娘改造",
982
+ "workbench.Ship initial equipment": "初期装備",
972
983
  "workbench.Sources": "入手元",
973
984
  "workbench.No known source": "既知の入手元なし",
974
985
  "workbench.Search sources": "入手元を検索",
@@ -1194,7 +1205,7 @@
1194
1205
  "workbench.Select an item to choose its Current start": "装備を選び、Current 開始地点を決めます",
1195
1206
  "workbench.The item stays outside Today until its Current start is resolved": "現在開始地点が確定するまで、この装備は Today に入りません",
1196
1207
  "shared.Choose a Current start before this plan can enter Today": "Current 開始地点を選ぶと、この計画を Today に出せます",
1197
- "shared.Current improvement starting point": "現在の改修開始地点",
1208
+ "shared.Current improvement starting point": "現在の改修開始点",
1198
1209
  "plan.Choose a Current start candidate before calculating the current execution cost.": "現在実行コストを計算する前に Current 開始候補を選択してください。",
1199
1210
  "plan.Current start selection is still incomplete": "現在開始地点の選択が未完了",
1200
1211
  "workbench.Choose a temporary Current start": "一時的な Current 開始地点を選択",
package/i18n/zh-CN.json CHANGED
@@ -370,6 +370,7 @@
370
370
  "equipment.Plan management": "计划管理",
371
371
  "equipment.Consumable plan": "耗材计划",
372
372
  "equipment.Materials insufficient": "材料不足",
373
+ "equipment.Acquire first": "先获取",
373
374
  "equipment.Clear": "清空",
374
375
  "equipment.Clear filters": "清除筛选",
375
376
  "equipment.Completed": "已完成",
@@ -933,12 +934,17 @@
933
934
  "shared.System-recommended improvement starting point": "系统推荐的改造起点",
934
935
  "shared.Select a valid route before the system can recommend a starting point": "选择有效路线后,系统才能推荐改造起点",
935
936
  "shared.Corresponding plan target": "对应计划目标",
937
+ "shared.Current plan target": "当前计划目标",
938
+ "shared.For plan": "用于",
936
939
  "shared.Related plans": "相关计划",
937
940
  "shared.Consumable plan": "耗材计划",
938
941
  "workbench.Plan targets": "计划目标",
939
942
  "workbench.Plan targets available for improvement on selected day": "今日可改",
940
- "workbench.No plan target is available for improvement on selected day": "当天没有可改的未完成计划目标",
943
+ "workbench.No plan target is available for improvement on selected day": "当天没有需要处理的未完成计划目标",
941
944
  "app.Left shows Plan targets that satisfy the selected day's improvement conditions.": "左侧展示当天满足改修条件的计划目标。",
945
+ "app.Review Current Plan actions today": "查看今天的当前计划动作",
946
+ "app.Left shows the next Current Plan action, including acquisition before improvement.": "左侧展示当前计划的下一动作,包括改修前需要先获取装备的情况。",
947
+ "app.Right shows the selected Current Start; low-cost acquisition and equipment-conversion Alternatives remain user-selectable.": "右侧展示已选择的当前起点;低成本获取与装备改修转换备选都保留给用户选择。",
942
948
  "data.Data management": "数据管理",
943
949
  "data.Export plans, route choices, and interface settings to a data file": "导出改修计划、路线选择和界面设置。",
944
950
  "data.Import plans, route choices, and interface settings from a data file": "从数据文件导入改修计划、路线选择和界面设置。",
@@ -955,7 +961,7 @@
955
961
  "equipment.Search and sort": "搜索与排序",
956
962
  "workbench.Clear filters": "清除筛选",
957
963
  "workbench.Display scope": "显示范围",
958
- "workbench.Today improvable": "今日可改",
964
+ "workbench.Today improvable": "今天改什么",
959
965
  "equipment.Plan %d": "计划 %d",
960
966
  "workbench.Available dates": "可改日期",
961
967
  "workbench.Expected materials for this upgrade": "本次升级期望材料",
@@ -969,6 +975,11 @@
969
975
  "workbench.Improvement source": "改修来源",
970
976
  "workbench.Periodic quest": "周期任务",
971
977
  "workbench.Ship source": "舰娘来源",
978
+ "workbench.Acquire Current start": "获取当前起点",
979
+ "workbench.Obtain this Current start before improvement": "改修前先获取这个 Current 起点",
980
+ "workbench.The selected Current start is not owned yet; acquire it first, then continue the selected route.": "当前还没有选中的起点装备;先通过下面的方式获得,再继续所选路线。",
981
+ "workbench.Ship remodel at Lv.%d": "Lv.%d 舰娘改造获得",
982
+ "workbench.Ship initial equipment": "初始装备",
972
983
  "workbench.Sources": "来源",
973
984
  "workbench.No known source": "暂无已知来源",
974
985
  "workbench.Search sources": "搜索来源",
@@ -1194,12 +1205,12 @@
1194
1205
  "workbench.Select an item to choose its Current start": "选择一个装备,为它确定 Current 起点",
1195
1206
  "workbench.The item stays outside Today until its Current start is resolved": "当前起点确定之前,该装备不会进入“今天改什么”",
1196
1207
  "shared.Choose a Current start before this plan can enter Today": "选择当前起点后,这个计划才能进入“今天改什么”",
1197
- "shared.Current improvement starting point": "当前改造起点",
1208
+ "shared.Current improvement starting point": "当前改修起点",
1198
1209
  "plan.Choose a Current start candidate before calculating the current execution cost.": "请先选择 Current 起点候选,再计算当前执行成本。",
1199
1210
  "plan.Current start selection is still incomplete": "当前起点尚未选择",
1200
1211
  "workbench.Choose a temporary Current start": "选择临时 Current 起点",
1201
- "workbench.Current improvement starting point": "当前改造起点",
1202
- "app.Review the current improvement starting point": "查看当前改造起点",
1212
+ "workbench.Current improvement starting point": "当前改修起点",
1213
+ "app.Review the current improvement starting point": "查看当前改修起点",
1203
1214
  "app.Right shows the Current Start selected from conservative candidates and current inventory.": "右侧展示从保守候选与当前库存中选定的 Current Start。",
1204
1215
  "app.Low-priority equipment guide": "低优先装备指南",
1205
1216
  "app.Review low-priority reasons, add recommended or manual entries, and remove multiple items at once.": "查看低优先原因,添加推荐或手动条目,并可批量移除。"
package/i18n/zh-TW.json CHANGED
@@ -370,6 +370,7 @@
370
370
  "equipment.Plan management": "計畫管理",
371
371
  "equipment.Consumable plan": "耗材計畫",
372
372
  "equipment.Materials insufficient": "材料不足",
373
+ "equipment.Acquire first": "先取得",
373
374
  "equipment.Clear": "清空",
374
375
  "equipment.Clear filters": "清除篩選",
375
376
  "equipment.Completed": "已完成",
@@ -933,12 +934,17 @@
933
934
  "shared.System-recommended improvement starting point": "系統推薦的改造起點",
934
935
  "shared.Select a valid route before the system can recommend a starting point": "選擇有效路線後,系統才能推薦改造起點",
935
936
  "shared.Corresponding plan target": "對應計畫目標",
937
+ "shared.Current plan target": "目前計畫目標",
938
+ "shared.For plan": "用於",
936
939
  "shared.Related plans": "相關計畫",
937
940
  "shared.Consumable plan": "耗材計畫",
938
941
  "workbench.Plan targets": "計畫目標",
939
942
  "workbench.Plan targets available for improvement on selected day": "今日可改",
940
- "workbench.No plan target is available for improvement on selected day": "當天沒有可改的未完成計畫目標",
943
+ "workbench.No plan target is available for improvement on selected day": "當天沒有需要處理的未完成計畫目標",
941
944
  "app.Left shows Plan targets that satisfy the selected day's improvement conditions.": "左側顯示當天符合改修條件的計畫目標。",
945
+ "app.Review Current Plan actions today": "查看今天的目前計畫動作",
946
+ "app.Left shows the next Current Plan action, including acquisition before improvement.": "左側顯示目前計畫的下一動作,包括改修前需要先取得裝備的情況。",
947
+ "app.Right shows the selected Current Start; low-cost acquisition and equipment-conversion Alternatives remain user-selectable.": "右側顯示已選擇的目前起點;低成本取得與裝備改修轉換備選都保留給使用者選擇。",
942
948
  "data.Data management": "資料管理",
943
949
  "data.Export plans, route choices, and interface settings to a data file": "匯出改修計畫、路線選擇與介面設定。",
944
950
  "data.Import plans, route choices, and interface settings from a data file": "從資料檔案匯入改修計畫、路線選擇與介面設定。",
@@ -955,7 +961,7 @@
955
961
  "equipment.Search and sort": "搜尋與排序",
956
962
  "workbench.Clear filters": "清除篩選",
957
963
  "workbench.Display scope": "顯示範圍",
958
- "workbench.Today improvable": "今日可改",
964
+ "workbench.Today improvable": "今天改什麼",
959
965
  "equipment.Plan %d": "計畫 %d",
960
966
  "workbench.Available dates": "可改日期",
961
967
  "workbench.Expected materials for this upgrade": "本次升級期望材料",
@@ -969,6 +975,11 @@
969
975
  "workbench.Improvement source": "改修來源",
970
976
  "workbench.Periodic quest": "週期任務",
971
977
  "workbench.Ship source": "艦娘來源",
978
+ "workbench.Acquire Current start": "取得目前起點",
979
+ "workbench.Obtain this Current start before improvement": "改修前先取得這個 Current 起點",
980
+ "workbench.The selected Current start is not owned yet; acquire it first, then continue the selected route.": "目前尚未持有所選的起點裝備;請先透過下列方式取得,再繼續所選路線。",
981
+ "workbench.Ship remodel at Lv.%d": "Lv.%d 艦娘改造取得",
982
+ "workbench.Ship initial equipment": "初始裝備",
972
983
  "workbench.Sources": "來源",
973
984
  "workbench.No known source": "暫無已知來源",
974
985
  "workbench.Search sources": "搜尋來源",
@@ -1194,12 +1205,12 @@
1194
1205
  "workbench.Select an item to choose its Current start": "選擇一件裝備,為它確定 Current 起點",
1195
1206
  "workbench.The item stays outside Today until its Current start is resolved": "目前起點確定之前,此裝備不會進入「今天改什麼」",
1196
1207
  "shared.Choose a Current start before this plan can enter Today": "選擇目前起點後,此計畫才能進入「今天改什麼」",
1197
- "shared.Current improvement starting point": "目前改造起點",
1208
+ "shared.Current improvement starting point": "目前改修起點",
1198
1209
  "plan.Choose a Current start candidate before calculating the current execution cost.": "請先選擇 Current 起點候選,再計算目前執行成本。",
1199
1210
  "plan.Current start selection is still incomplete": "目前起點尚未選擇",
1200
1211
  "workbench.Choose a temporary Current start": "選擇臨時 Current 起點",
1201
- "workbench.Current improvement starting point": "目前改造起點",
1202
- "app.Review the current improvement starting point": "查看目前改造起點",
1212
+ "workbench.Current improvement starting point": "目前改修起點",
1213
+ "app.Review the current improvement starting point": "查看目前改修起點",
1203
1214
  "app.Right shows the Current Start selected from conservative candidates and current inventory.": "右側顯示從保守候選與目前庫存中選定的 Current Start。",
1204
1215
  "app.Low-priority equipment guide": "低優先裝備指南",
1205
1216
  "app.Review low-priority reasons, add recommended or manual entries, and remove multiple items at once.": "查看低優先原因,加入建議或手動項目,並可批次移除。"
package/package.json CHANGED
@@ -99,5 +99,5 @@
99
99
  "title": "改修助手"
100
100
  },
101
101
  "private": false,
102
- "version": "1.0.1065-beta"
102
+ "version": "1.0.1069-beta"
103
103
  }
@@ -34,13 +34,13 @@ const HELP_AREAS = [{
34
34
  }, {
35
35
  key: 'targets',
36
36
  icon: 'list',
37
- title: 'Review plan targets available today',
38
- description: "Left shows Plan targets that satisfy the selected day's improvement conditions."
37
+ title: 'Review Current Plan actions today',
38
+ description: 'Left shows the next Current Plan action, including acquisition before improvement.'
39
39
  }, {
40
40
  key: 'starting-point',
41
41
  icon: 'play-circle',
42
42
  title: 'Review the current improvement starting point',
43
- description: 'Right shows the Current Start selected from conservative candidates and current inventory.'
43
+ description: 'Right shows the selected Current Start; low-cost acquisition and equipment-conversion Alternatives remain user-selectable.'
44
44
  }, {
45
45
  key: 'materials',
46
46
  icon: 'stats',
@@ -846,6 +846,8 @@ const selectWorkbenchItems = (items, options = {}) => {
846
846
  const resolved = actionable.filter(item => !item.routeSelectionRequired && !item.routeSelectionInvalid);
847
847
 
848
848
  const availableOnSelectedDay = item => {
849
+ const acquisitionAction = item && item.todayStage && item.todayStage.kind === 'missing-source' && item.currentStartAcquisition && item.currentStartAcquisition.available === true;
850
+ if (acquisitionAction) return true;
849
851
  if (selectedDay === null) return item.availability.availableToday;
850
852
  const availability = item.availability || {};
851
853
  const availableDays = availability.theoreticalDays;
@@ -168,12 +168,6 @@ class EquipmentList extends _react.Component {
168
168
  className: "decision-equipment-icon",
169
169
  masterEquips: masterEquips
170
170
  }), _react.default.createElement("span", {
171
- className: "decision-equipment-meta decision-workbench-tag-column"
172
- }, materialShortage && _react.default.createElement("span", {
173
- className: "decision-pill decision-pill-warning"
174
- }, __('Materials insufficient')), activePlan.planKind === 'consumable' && _react.default.createElement("span", {
175
- className: "decision-pill decision-pill-primary"
176
- }, __('Consumable plan'))), _react.default.createElement("span", {
177
171
  className: "decision-equipment-main decision-workbench-name-column"
178
172
  }, _react.default.createElement("span", {
179
173
  className: "decision-equipment-title"
@@ -182,7 +176,15 @@ class EquipmentList extends _react.Component {
182
176
  title: localizedEquipmentName
183
177
  }, _react.default.createElement(EquipmentName, {
184
178
  name: localizedEquipmentName
185
- })))));
179
+ })))), _react.default.createElement("span", {
180
+ className: "decision-equipment-meta decision-workbench-tag-column"
181
+ }, activePlan.todayStage && activePlan.todayStage.kind === 'missing-source' && activePlan.currentStartAcquisition && activePlan.currentStartAcquisition.available === true && _react.default.createElement("span", {
182
+ className: "decision-pill decision-pill-warning"
183
+ }, __('Acquire first')), materialShortage && activePlan.todayStage && activePlan.todayStage.kind !== 'missing-source' && _react.default.createElement("span", {
184
+ className: "decision-pill decision-pill-warning"
185
+ }, __('Materials insufficient')), activePlan.planKind === 'consumable' && _react.default.createElement("span", {
186
+ className: "decision-pill decision-pill-primary"
187
+ }, __('Consumable plan'))));
186
188
  }
187
189
 
188
190
  return _react.default.createElement("button", {
@@ -294,44 +294,23 @@ const buildCommonEquipmentAcquisitionIndex = staticItems => Object.keys(staticIt
294
294
  return result;
295
295
  }, {}); // Current Start candidate search intentionally optimizes for recall rather than
296
296
  // automatic route choice. This Acquisition Domain function is the single
297
- // authority for which external source facts are conservative enough to surface
298
- // as a selectable Current start candidate. It does not rank or select them.
297
+ // authority for which external source facts are low-cost enough to make an
298
+ // unowned ★0 a formal Current Start Alternative. It does not rank or select
299
+ // among those alternatives; recommendation/presentation must not prune them.
299
300
 
300
301
 
301
302
  exports.buildCommonEquipmentAcquisitionIndex = buildCommonEquipmentAcquisitionIndex;
302
303
 
303
304
  const currentStartEquipmentAcquisition = section => {
304
- const acquisition = section || {};
305
- const sources = [];
306
-
307
- if (acquisition.developmentAvailable === true) {
308
- sources.push({
309
- kind: COMMON_ACQUISITION_KIND.DEVELOPMENT
310
- });
311
- }
312
-
313
- ;
314
- (acquisition.periodicQuests || []).forEach(quest => {
315
- sources.push({
316
- kind: COMMON_ACQUISITION_KIND.PERIODIC_QUEST,
317
- questKey: questKeyOf(quest && (quest.questKey || quest.questId || quest.id || quest.code)),
318
- quest: quest || null
319
- });
320
- });
321
- (acquisition.shipSources || []).forEach(source => {
322
- sources.push({
323
- kind: COMMON_ACQUISITION_KIND.SHIP_EQUIPMENT,
324
- shipId: Number(source && source.shipId) || 0,
325
- shipName: String(source && source.shipName || ''),
326
- method: source && source.method === 'remodel' ? 'remodel' : 'initial',
327
- quantity: Number(source && source.quantity) || 0,
328
- remodelLevel: Number(source && source.remodelLevel) || 0,
329
- shipAvailability: Array.isArray(source && source.shipAvailability) ? source.shipAvailability.slice() : []
330
- });
331
- });
305
+ // Current Start may treat an unowned ★0 state as a formal route entry only
306
+ // when Acquisition Value already classifies the source as low-cost. Reuse
307
+ // that authority verbatim: this view must not independently reinterpret raw
308
+ // development / quest / ship facts or surface known expensive ship stages as
309
+ // if they were equivalent entry points.
310
+ const lowCost = evaluateEquipmentAcquisitionValue(section).lowCost;
332
311
  return Object.freeze({
333
- available: sources.length > 0,
334
- sources: Object.freeze(sources)
312
+ available: lowCost.available === true,
313
+ sources: Object.freeze((lowCost.sources || []).slice())
335
314
  });
336
315
  };
337
316
 
@@ -53,6 +53,7 @@ const parentIdentity = entry => {
53
53
 
54
54
  const collectConsumablePlanDemands = (workbenchItems, acquisitionValueIndex = {}) => {
55
55
  const grouped = {};
56
+ const frontParentPlanIdByEquipment = {};
56
57
  (workbenchItems || []).forEach(entry => {
57
58
  const parent = parentIdentity(entry);
58
59
  if (!parent) return;
@@ -69,7 +70,15 @@ const collectConsumablePlanDemands = (workbenchItems, acquisitionValueIndex = {}
69
70
 
70
71
  const acquisitionValue = acquisitionValueIndex[equipmentId] || {};
71
72
  const lowCost = acquisitionValue.lowCost || acquisitionValue;
72
- if (lowCost.available === true) return;
73
+ if (lowCost.available === true) return; // A derived Consumable Plan is a local dependency of one Current parent,
74
+ // not a cross-Plan reservation system. For the same missing equipment,
75
+ // only the first Current parent in the Base Workbench projection owns the
76
+ // derived demand. Later parents remain visible as their own future demand
77
+ // and will become eligible after the front parent disappears or advances.
78
+
79
+ const frontParentPlanId = frontParentPlanIdByEquipment[equipmentId];
80
+ if (frontParentPlanId && frontParentPlanId !== parent.planId) return;
81
+ if (!frontParentPlanId) frontParentPlanIdByEquipment[equipmentId] = parent.planId;
73
82
  const key = `${parent.planId}:${equipmentId}:${CONSUMABLE_PLAN_STAR}`;
74
83
 
75
84
  if (!grouped[key]) {
@@ -432,12 +432,15 @@ const buildCurrentStartPlanningStates = input => {
432
432
  id: analysis.id,
433
433
  level: Number(analysis.goal && analysis.goal.star) || 0
434
434
  };
435
- const targetKnown = graphContainsNode(graph, target);
436
- const crossEquipment = targetKnown && hasCrossEquipmentPredecessor(graph, target);
435
+ const targetKnownInGraph = graphContainsNode(graph, target);
436
+ const hasAcquisitionStart = currentStartOptions.some(option => option && option.currentStartKind === CURRENT_START_KIND.ACQUISITION);
437
+ const targetKnown = targetKnownInGraph || hasAcquisitionStart;
438
+ const crossEquipment = targetKnownInGraph && hasCrossEquipmentPredecessor(graph, target);
437
439
  const requirement = currentStartSelectionRequirement({
438
440
  analysis
439
441
  });
440
- const status = !targetKnown ? CURRENT_START_PLANNING_STATUS.UNREACHABLE : crossEquipment ? currentStartOptions.length > 0 ? CURRENT_START_PLANNING_STATUS.READY : CURRENT_START_PLANNING_STATUS.UNREACHABLE : CURRENT_START_PLANNING_STATUS.DIRECT_ONLY;
442
+ const needsCurrentStartPlanning = crossEquipment || hasAcquisitionStart;
443
+ const status = !targetKnown ? CURRENT_START_PLANNING_STATUS.UNREACHABLE : needsCurrentStartPlanning ? currentStartOptions.length > 0 ? CURRENT_START_PLANNING_STATUS.READY : CURRENT_START_PLANNING_STATUS.UNREACHABLE : CURRENT_START_PLANNING_STATUS.DIRECT_ONLY;
441
444
  return {
442
445
  id: analysis.id,
443
446
  status,
@@ -21,8 +21,6 @@ var _improvementPlanDomain = require("../../plan/domain/improvement-plan-domain"
21
21
 
22
22
  var _currentPlanExecutionDomain = require("../../plan/domain/current-plan-execution-domain");
23
23
 
24
- var _planRoutePresentation = require("../../plan/model/plan-route-presentation");
25
-
26
24
  var _workbenchDetail = require("../../workbench/components/workbench-detail");
27
25
 
28
26
  var _upgradeRouteModal = require("../../chain/full/upgrade-route-modal");
@@ -53,12 +51,23 @@ const currentExecutionLevel = item => {
53
51
  return stage.sourceLevel;
54
52
  }
55
53
 
54
+ if (stage && stage.kind === 'missing-source' && item && item.requiredStart && item.requiredStart.level !== null && item.requiredStart.level !== undefined) {
55
+ return Number(item.requiredStart.level);
56
+ }
57
+
56
58
  const action = item && item.action;
57
59
  return action ? action.sourceLevel : null;
58
60
  };
59
61
 
60
62
  const planReferenceLevelText = level => Number(level) === 10 ? '+max' : `+${Math.max(Number(level) || 0, 0)}`;
61
63
 
64
+ const equipmentPlanText = (masterEquips, equipmentId, star) => {
65
+ const id = Number(equipmentId) || 0;
66
+ const master = masterEquips && (masterEquips[id] || masterEquips[String(id)]) || {};
67
+ const name = master.api_name ? localizedName(master.api_name) : `#${id}`;
68
+ return `${name} ${planReferenceLevelText(star)}`.trim();
69
+ };
70
+
62
71
  const buildRelatedPlanReferences = item => {
63
72
  const planState = item && item.planState ? item.planState : {};
64
73
  const goals = Array.isArray(planState.configuredGoals) ? planState.configuredGoals : [];
@@ -70,18 +79,53 @@ const buildRelatedPlanReferences = item => {
70
79
  const normalTarget = consumable && star === consumableStar ? Math.max(Number(consumable.baseTarget) || 0, 0) : target;
71
80
  return normalTarget > 0 ? result.concat({
72
81
  kind: 'normal',
82
+ equipmentId: Number(item && item.id) || 0,
73
83
  star,
74
84
  count: normalTarget
75
85
  }) : result;
76
86
  }, []);
77
87
 
78
88
  if (consumable && Number(consumable.consumableTarget) > 0) {
79
- references.push({
80
- kind: 'consumable',
81
- star: consumableStar,
82
- count: Number(consumable.consumableTarget),
83
- parentPlanIds: Array.isArray(consumable.parentPlanIds) ? consumable.parentPlanIds.slice() : []
84
- });
89
+ const demands = Array.isArray(consumable.consumableDemands) ? consumable.consumableDemands : [];
90
+ const parentReferences = demands.reduce((result, demand) => {
91
+ const parentEquipmentId = Number(demand && demand.parentEquipmentId) || 0;
92
+ const parentStar = Number(demand && demand.parentStar);
93
+ const count = Number(demand && demand.count) || 0;
94
+ const parentPlanId = String(demand && demand.parentPlanId || '');
95
+
96
+ if (!parentEquipmentId || !Number.isInteger(parentStar) || parentStar < 0 || !count) {
97
+ return result;
98
+ }
99
+
100
+ const key = parentPlanId || `${parentEquipmentId}:${parentStar}`;
101
+ const current = result[key] || {
102
+ kind: 'consumable',
103
+ equipmentId: Number(consumable.equipmentId || item && item.id) || 0,
104
+ star: consumableStar,
105
+ count: 0,
106
+ parentPlanId,
107
+ parentEquipmentId,
108
+ parentStar
109
+ };
110
+ return _extends({}, result, {
111
+ [key]: _extends({}, current, {
112
+ count: current.count + count
113
+ })
114
+ });
115
+ }, {});
116
+ const resolved = Object.keys(parentReferences).sort().map(key => parentReferences[key]);
117
+
118
+ if (resolved.length > 0) {
119
+ references.push(...resolved);
120
+ } else {
121
+ references.push({
122
+ kind: 'consumable',
123
+ equipmentId: Number(consumable.equipmentId || item && item.id) || 0,
124
+ star: consumableStar,
125
+ count: Number(consumable.consumableTarget),
126
+ parentPlanIds: Array.isArray(consumable.parentPlanIds) ? consumable.parentPlanIds.slice() : []
127
+ });
128
+ }
85
129
  }
86
130
 
87
131
  return references;
@@ -92,8 +136,7 @@ exports.buildRelatedPlanReferences = buildRelatedPlanReferences;
92
136
  const planTargetSummary = item => {
93
137
  const goal = item && item.planState ? item.planState.activeGoal : null;
94
138
  const level = item && item.finalTargetLevel !== null && item.finalTargetLevel !== undefined ? item.finalTargetLevel : goal ? goal.star : null;
95
- const count = (0, _planRoutePresentation.projectedPlanTargetCount)(item);
96
- return `${localizedName(item && item.row && item.row.api_name)} ${levelText(level)}${count === null ? '' : ` ×${count}`}`.trim();
139
+ return `${localizedName(item && item.row && item.row.api_name)} ${levelText(level)}`.trim();
97
140
  };
98
141
 
99
142
  class DetailPanel extends _react.Component {
@@ -315,7 +358,7 @@ class DetailPanel extends _react.Component {
315
358
  className: "decision-detail-current-level"
316
359
  }, levelText(executionLevel))), isPlanWorkbenchItem && _react.default.createElement("div", {
317
360
  className: "decision-detail-plan-target"
318
- }, _react.default.createElement("span", null, __('Corresponding plan target')), _react.default.createElement("strong", null, planTargetSummary(item)))), isPlanWorkbenchItem && relatedPlans.length > 0 && _react.default.createElement("div", {
361
+ }, _react.default.createElement("span", null, __('Current plan target')), _react.default.createElement("strong", null, planTargetSummary(item)))), isPlanWorkbenchItem && relatedPlans.length > 0 && _react.default.createElement("div", {
319
362
  className: "decision-detail-related-plans"
320
363
  }, _react.default.createElement("span", {
321
364
  className: "decision-detail-related-plans-label"
@@ -324,7 +367,9 @@ class DetailPanel extends _react.Component {
324
367
  }, relatedPlans.map((reference, index) => _react.default.createElement("span", {
325
368
  className: `decision-detail-related-plan${reference.kind === 'consumable' ? ' is-consumable' : ''}`,
326
369
  key: `${reference.kind}-${reference.star}-${index}`
327
- }, reference.kind === 'consumable' && _react.default.createElement("em", null, __('Consumable plan')), _react.default.createElement("strong", null, `${planReferenceLevelText(reference.star)} ×${reference.count}`)))))), this.renderDetail(item, this.getActiveRouteIndex(item))) : _react.default.createElement(_react.default.Fragment, null, _react.default.createElement("span", {
370
+ }, reference.kind === 'consumable' && _react.default.createElement("em", null, __('Consumable plan')), _react.default.createElement("strong", null, `${equipmentPlanText(masterEquips, reference.equipmentId || item.id, reference.star)} ×${reference.count}`), reference.kind === 'consumable' && reference.parentEquipmentId && _react.default.createElement("span", {
371
+ className: "decision-detail-related-plan-parent"
372
+ }, `→ ${__('For plan')} ${equipmentPlanText(masterEquips, reference.parentEquipmentId, reference.parentStar)}`)))))), this.renderDetail(item, this.getActiveRouteIndex(item))) : _react.default.createElement(_react.default.Fragment, null, _react.default.createElement("span", {
328
373
  className: "glyphicon glyphicon-hand-left",
329
374
  "aria-hidden": "true"
330
375
  }), _react.default.createElement("strong", null, __('Select equipment to see the decision details')))))), _react.default.createElement(_upgradeRouteModal.UpgradeRouteModal, {
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
 
3
3
  exports.__esModule = true;
4
- exports.WorkbenchDetail = exports.TodaySummarySection = exports.AssistantSection = void 0;
4
+ exports.currentStartAcquisitionLines = exports.WorkbenchDetail = exports.TodaySummarySection = exports.CurrentStartAcquisitionSection = exports.AssistantSection = void 0;
5
5
 
6
6
  var _react = _interopRequireDefault(require("react"));
7
7
 
@@ -139,6 +139,58 @@ TodaySummarySection.propTypes = {
139
139
  currentDay: _propTypes.default.number.isRequired
140
140
  };
141
141
 
142
+ const currentStartAcquisitionLines = acquisition => {
143
+ const lines = [];
144
+ (acquisition && acquisition.sources || []).forEach(source => {
145
+ if (!source) return;
146
+
147
+ if (source.kind === 'development') {
148
+ lines.push(__('Development'));
149
+ return;
150
+ }
151
+
152
+ if (source.kind === 'periodic-quest') {
153
+ const quest = source.quest || {};
154
+ const label = quest.name || quest.title || quest.questName || source.questKey || '?';
155
+ lines.push(`${__('Periodic quest')}: ${label}`);
156
+ return;
157
+ }
158
+
159
+ if (source.kind === 'ship-equipment') {
160
+ const shipName = String(source.shipName || '').trim() || `#${Number(source.shipId) || 0}`;
161
+ const remodelLevel = Number(source.remodelLevel) || 0;
162
+ const sourceDetail = source.method === 'remodel' ? __('Ship remodel at Lv.%d').replace('%d', remodelLevel || '?') : __('Ship initial equipment');
163
+ lines.push(`${__('Ship source')}: ${shipName} · ${sourceDetail}`);
164
+ }
165
+ });
166
+ return Array.from(new Set(lines));
167
+ };
168
+
169
+ exports.currentStartAcquisitionLines = currentStartAcquisitionLines;
170
+
171
+ const CurrentStartAcquisitionSection = ({
172
+ acquisition
173
+ }) => {
174
+ const lines = currentStartAcquisitionLines(acquisition);
175
+ return _react.default.createElement("section", {
176
+ className: "decision-workbench-detail-section decision-workbench-current-start-acquisition"
177
+ }, _react.default.createElement("div", {
178
+ className: "decision-guidance-callout is-info"
179
+ }, _react.default.createElement("span", {
180
+ className: "glyphicon glyphicon-download-alt",
181
+ "aria-hidden": "true"
182
+ }), _react.default.createElement("div", null, _react.default.createElement("strong", null, __('Obtain this Current start before improvement')), _react.default.createElement("span", null, __('The selected Current start is not owned yet; acquire it first, then continue the selected route.')), lines.length > 0 && _react.default.createElement("ul", {
183
+ className: "decision-workbench-acquisition-source-list"
184
+ }, lines.map(line => _react.default.createElement("li", {
185
+ key: line
186
+ }, line))))));
187
+ };
188
+
189
+ exports.CurrentStartAcquisitionSection = CurrentStartAcquisitionSection;
190
+ CurrentStartAcquisitionSection.propTypes = {
191
+ acquisition: _propTypes.default.object.isRequired
192
+ };
193
+
142
194
  const WorkbenchDetail = ({
143
195
  item,
144
196
  targetItem,
@@ -165,6 +217,8 @@ const WorkbenchDetail = ({
165
217
  selectedEquipmentIds,
166
218
  selectedConnections
167
219
  } = planResolution;
220
+ const currentStartAcquisition = targetItem.currentStartAcquisition || item && item.currentStartAcquisition || null;
221
+ const acquisitionRequired = Boolean(targetItem.todayStage && targetItem.todayStage.kind === 'missing-source' && currentStartAcquisition && currentStartAcquisition.available === true);
168
222
 
169
223
  if (targetItem.routeSelectionRequired || targetItem.routeSelectionInvalid) {
170
224
  return _react.default.createElement("div", {
@@ -210,7 +264,13 @@ const WorkbenchDetail = ({
210
264
  active: routeIndex === index,
211
265
  key: candidate.routeId || `route-${index + 1}`,
212
266
  onClick: () => onRouteSelect(index)
213
- }, __('Route %d').replace('%d', index + 1))))), _react.default.createElement(_detailPlugin.DetailPlugin, {
267
+ }, __('Route %d').replace('%d', index + 1))))), acquisitionRequired && _react.default.createElement(_detailPlugin.DetailPlugin, {
268
+ pluginKey: "workbench-current-start-acquisition",
269
+ icon: "download-alt",
270
+ title: __('Acquire Current start')
271
+ }, _react.default.createElement(CurrentStartAcquisitionSection, {
272
+ acquisition: currentStartAcquisition
273
+ })), !acquisitionRequired && _react.default.createElement(_react.default.Fragment, null, _react.default.createElement(_detailPlugin.DetailPlugin, {
214
274
  pluginKey: "workbench-assistant",
215
275
  icon: "user",
216
276
  title: __('Assistant ship')
@@ -242,7 +302,7 @@ const WorkbenchDetail = ({
242
302
  resourceBudget: resourceBudget,
243
303
  staticItems: staticItems,
244
304
  onOpenMaterialDetail: onOpenMaterialDetail
245
- }))), _react.default.createElement(_detailPlugin.DetailPlugin, {
305
+ })))), _react.default.createElement(_detailPlugin.DetailPlugin, {
246
306
  pluginKey: "workbench-evolution-chain",
247
307
  icon: "random",
248
308
  title: __('Evolution chain')