@@ -157,9 +157,13 @@ export class AnnouncementController {
157157
158158 const limit = AnnouncementView . PAGE_SIZE ;
159159 const offset = Number ( body . view ?. private_metadata ?? '0' ) ;
160- const { items, total } = await this . announcementService . findPage ( offset , limit ) ;
160+ const { items, total } = await this . announcementService . findPage (
161+ offset ,
162+ limit ,
163+ ) ;
161164 // 삭제 후 현재 페이지 항목이 없으면 이전 페이지로 이동
162- const adjustedOffset = items . length === 0 && offset > 0 ? offset - limit : offset ;
165+ const adjustedOffset =
166+ items . length === 0 && offset > 0 ? offset - limit : offset ;
163167 const page =
164168 adjustedOffset !== offset
165169 ? await this . announcementService . findPage ( adjustedOffset , limit )
@@ -181,15 +185,17 @@ export class AnnouncementController {
181185 /** 이전 페이지 — action.value = 이동할 offset */
182186 @Action ( 'announcement:list:prev' )
183187 async handleListPrev (
184- args : SlackActionMiddlewareArgs < BlockAction < ButtonAction > > & AllMiddlewareArgs ,
188+ args : SlackActionMiddlewareArgs < BlockAction < ButtonAction > > &
189+ AllMiddlewareArgs ,
185190 ) {
186191 return this . handleListPage ( args ) ;
187192 }
188193
189194 /** 다음 페이지 — action.value = 이동할 offset */
190195 @Action ( 'announcement:list:next' )
191196 async handleListNext (
192- args : SlackActionMiddlewareArgs < BlockAction < ButtonAction > > & AllMiddlewareArgs ,
197+ args : SlackActionMiddlewareArgs < BlockAction < ButtonAction > > &
198+ AllMiddlewareArgs ,
193199 ) {
194200 return this . handleListPage ( args ) ;
195201 }
@@ -204,7 +210,10 @@ export class AnnouncementController {
204210
205211 const offset = Number ( action . value ) ;
206212 const limit = AnnouncementView . PAGE_SIZE ;
207- const { items, total } = await this . announcementService . findPage ( offset , limit ) ;
213+ const { items, total } = await this . announcementService . findPage (
214+ offset ,
215+ limit ,
216+ ) ;
208217
209218 const viewId = body . view ?. id ;
210219 if ( ! viewId ) {
@@ -292,8 +301,9 @@ export class AnnouncementController {
292301 values . channel_block . channel_input . selected_option ?. value ?? '' ;
293302 const title = values . title_block . title_input . value ?? '' ;
294303 // rich_text_input은 rich_text_value로 읽음 (Slack Block Kit 타입 미지원 → any 캐스팅)
295- // eslint-disable-next-line @typescript-eslint/no-explicit-any
296- const richTextBlock = ( values . content_block ?. content_input as any ) ?. rich_text_value ?? null ;
304+
305+ const richTextBlock =
306+ ( values . content_block ?. content_input as any ) ?. rich_text_value ?? null ;
297307
298308 if ( ! channelId ) {
299309 await ack ( {
@@ -315,7 +325,10 @@ export class AnnouncementController {
315325 const contentJson = JSON . stringify ( richTextBlock ) ;
316326
317327 try {
318- const message = AnnouncementView . announcementMessage ( title , richTextBlock ) ;
328+ const message = AnnouncementView . announcementMessage (
329+ title ,
330+ richTextBlock ,
331+ ) ;
319332 const result = await client . chat . postMessage ( {
320333 channel : channelId ,
321334 text : message . text ,
@@ -378,8 +391,9 @@ export class AnnouncementController {
378391 const id = Number ( view . private_metadata ) ;
379392 const values = view . state . values ;
380393 const title = values . title_block . title_input . value ?? '' ;
381- // eslint-disable-next-line @typescript-eslint/no-explicit-any
382- const richTextBlock = ( values . content_block ?. content_input as any ) ?. rich_text_value ?? null ;
394+
395+ const richTextBlock =
396+ ( values . content_block ?. content_input as any ) ?. rich_text_value ?? null ;
383397
384398 if ( ! richTextBlock ) {
385399 await ack ( {
@@ -404,15 +418,21 @@ export class AnnouncementController {
404418 }
405419
406420 try {
407- const message = AnnouncementView . announcementMessage ( title , richTextBlock ) ;
421+ const message = AnnouncementView . announcementMessage (
422+ title ,
423+ richTextBlock ,
424+ ) ;
408425 await client . chat . update ( {
409426 channel : announcement . channelId ,
410427 ts : announcement . messageTs ,
411428 text : message . text ,
412429 blocks : message . blocks ,
413430 } ) ;
414431
415- await this . announcementService . update ( id , { title, content : contentJson } ) ;
432+ await this . announcementService . update ( id , {
433+ title,
434+ content : contentJson ,
435+ } ) ;
416436
417437 this . logger . log (
418438 `공지 수정 완료 — id: ${ id } , channel: ${ announcement . channelId } ` ,
0 commit comments