Skip to content

Commit c0b953f

Browse files
Copilothotlong
andcommitted
Move calendar-view renderer to plugin and remove from components package
Co-authored-by: hotlong <50353452+hotlong@users.noreply.github.com>
1 parent 52cc1f2 commit c0b953f

File tree

4 files changed

+4
-25
lines changed

4 files changed

+4
-25
lines changed

packages/components/src/__tests__/complex-disclosure-renderers.test.tsx

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -224,29 +224,6 @@ describe('Complex Renderers - Display Issue Detection', () => {
224224
});
225225
});
226226

227-
describe('Calendar View Renderer', () => {
228-
it('should be properly registered', () => {
229-
const validation = validateComponentRegistration('calendar-view');
230-
expect(validation.isRegistered).toBe(true);
231-
});
232-
233-
it('should render calendar view', () => {
234-
const { container } = renderComponent({
235-
type: 'calendar-view',
236-
events: [
237-
{
238-
id: '1',
239-
title: 'Event 1',
240-
start: '2024-01-01',
241-
end: '2024-01-01',
242-
},
243-
],
244-
});
245-
246-
expect(container).toBeDefined();
247-
});
248-
});
249-
250227
describe('Table Renderer', () => {
251228
it('should be properly registered', () => {
252229
const validation = validateComponentRegistration('table');

packages/components/src/renderers/complex/index.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
* LICENSE file in the root directory of this source tree.
77
*/
88

9-
import './calendar-view';
109
import './carousel';
1110
import './filter-builder';
1211
import './scroll-area';

packages/plugin-calendar-view/src/index.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -501,3 +501,6 @@ function DayView({ date, events, onEventClick }: DayViewProps) {
501501
}
502502

503503
export { CalendarView }
504+
505+
// Export renderer to register the component with ObjectUI
506+
export * from './renderer';

packages/components/src/renderers/complex/calendar-view.tsx renamed to packages/plugin-calendar-view/src/renderer.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
import { ComponentRegistry } from '@object-ui/core';
1010
import type { CalendarViewSchema, CalendarEvent } from '@object-ui/types';
11-
import { CalendarView } from '../../ui';
11+
import { CalendarView } from './index';
1212
import React from 'react';
1313

1414
// Calendar View Renderer - Airtable-style calendar for displaying records as events

0 commit comments

Comments
 (0)