feat(org-chart): support standalone React integration and update guides
This commit is contained in:
1 parent
5acaf8a295
commit
b637f86631
19 files changed
+1455
-64
No files matched your search
@@ -228,14 +228,21 @@ Fixed의 CSS·엔진 옵션·기존 native 팝업은 보존한다.
|
||||
노출을 제공한다. Fit/100% 복원은 Zoom/Pan 사용 여부와 독립적으로 가능하다.
|
||||
2,100명 전체 Fit은 개요용으로 작게 축소되므로 카드 읽기에는 Zoom 또는 초기 Depth를 사용한다.
|
||||
|
||||
React에서 `employeePopup="hm-dialog"`는 실제 공개 HM Dialog·Avatar·Button을 사용한다.
|
||||
React에서 명시적인 `@hm-design/org-chart-react/hm-dialog` Entry와
|
||||
`employeePopup="hm-dialog"`는 실제 공개 HM Dialog·Avatar·Button을 사용한다.
|
||||
`'core'`가 기본, `'none'`은 카드의 클릭·button 의미를 제거하되 키보드 이동용 초점은 유지한다. `onEmployeeClick`을
|
||||
지정하면 선택 모드와 관계없이 callback이 우선한다. HM 모드는
|
||||
`@hm-design/ui@0.1.0` optional peer와 호스트 `index.css → hm-theme.css` 연결이 필요하다.
|
||||
Core/Vanilla에는 React/HM 의존성을 추가하지 않았다. peer 없는 호스트의 모든 bundler
|
||||
조합 및 fresh install은 별도 미검증이다.
|
||||
기본 Entry `@hm-design/org-chart-react`는 HM runtime/type Import 없이 Core 팝업을
|
||||
사용한다. UI 설치만으로 전환하지 않는다. 다른 디자인 시스템은 기본 Entry에서
|
||||
`employeePopup="adapter"`와 `employeePopupAdapter`를 명시하여 연결한다.
|
||||
Core/Vanilla와 기존 데이터에는 React/HM 의존성이나 변경을 추가하지 않았다.
|
||||
기존 HM 소비자는 Import만 `/hm-dialog`로 변경하고 기존 Props를 유지한다.
|
||||
모든 bundler 조합은 별도 미검증이다.
|
||||
|
||||
```tsx
|
||||
import { OrgChart } from '@hm-design/org-chart-react/hm-dialog';
|
||||
|
||||
<OrgChart dataSource={source} stylesheetUrls={stylesheets} layoutMode="auto"
|
||||
autoLayout={{ type: 'lr', initialVisibleDepth: 2 }}
|
||||
interactions={{ collapse: false, zoom: true, pan: false }}
|
||||
|
||||
Reference in new issue
Block a user