analytica-frontend-lib 1.2.36 → 1.2.37

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/dist/index.mjs CHANGED
@@ -11703,6 +11703,115 @@ var createActivityFiltersDataHook = (apiClient) => {
11703
11703
  return createUseActivityFiltersData(apiClient);
11704
11704
  };
11705
11705
 
11706
+ // src/hooks/useQuestionsList.ts
11707
+ import { useState as useState22, useCallback as useCallback4 } from "react";
11708
+ var useQuestionsListImpl = (apiClient) => {
11709
+ const [state, setState] = useState22({
11710
+ questions: [],
11711
+ pagination: null,
11712
+ loading: false,
11713
+ loadingMore: false,
11714
+ error: null,
11715
+ currentFilters: null
11716
+ });
11717
+ const updateState = useCallback4((updates) => {
11718
+ setState((prev) => ({ ...prev, ...updates }));
11719
+ }, []);
11720
+ const handleError = useCallback4(
11721
+ (error) => {
11722
+ console.error("Erro ao carregar quest\xF5es:", error);
11723
+ let errorMessage = "Erro ao carregar quest\xF5es";
11724
+ if (error && typeof error === "object" && "response" in error) {
11725
+ const axiosError = error;
11726
+ errorMessage = axiosError?.response?.data?.message || axiosError?.message || errorMessage;
11727
+ } else if (error instanceof Error) {
11728
+ errorMessage = error.message;
11729
+ }
11730
+ updateState({
11731
+ loading: false,
11732
+ loadingMore: false,
11733
+ error: errorMessage
11734
+ });
11735
+ },
11736
+ [updateState]
11737
+ );
11738
+ const fetchQuestions = useCallback4(
11739
+ async (filters, append = false) => {
11740
+ if (append) {
11741
+ setState((prev) => ({ ...prev, loadingMore: true, error: null }));
11742
+ } else {
11743
+ updateState({ loading: true, error: null, questions: [] });
11744
+ }
11745
+ try {
11746
+ const validatedFilters = {
11747
+ ...filters
11748
+ };
11749
+ const response = await apiClient.post(
11750
+ "/questions/list",
11751
+ validatedFilters
11752
+ );
11753
+ setState((prev) => ({
11754
+ loading: false,
11755
+ loadingMore: false,
11756
+ questions: append ? [...prev.questions, ...response.data.data.questions] : response.data.data.questions,
11757
+ pagination: response.data.data.pagination,
11758
+ error: null,
11759
+ currentFilters: validatedFilters
11760
+ }));
11761
+ } catch (error) {
11762
+ setState((prev) => ({
11763
+ ...prev,
11764
+ loading: false,
11765
+ loadingMore: false
11766
+ }));
11767
+ handleError(error);
11768
+ }
11769
+ },
11770
+ [apiClient, updateState, handleError]
11771
+ );
11772
+ const loadMore = useCallback4(async () => {
11773
+ setState((prev) => {
11774
+ const { currentFilters, pagination, loadingMore: isLoadingMore } = prev;
11775
+ if (isLoadingMore || !currentFilters || !pagination?.hasNext) {
11776
+ return prev;
11777
+ }
11778
+ const nextPageFilters = {
11779
+ ...currentFilters,
11780
+ page: pagination.page + 1
11781
+ };
11782
+ fetchQuestions(nextPageFilters, true).catch((error) => {
11783
+ console.error("Erro ao carregar mais quest\xF5es:", error);
11784
+ });
11785
+ return {
11786
+ ...prev,
11787
+ loadingMore: true
11788
+ };
11789
+ });
11790
+ }, [fetchQuestions]);
11791
+ const reset = useCallback4(() => {
11792
+ setState({
11793
+ questions: [],
11794
+ pagination: null,
11795
+ loading: false,
11796
+ loadingMore: false,
11797
+ error: null,
11798
+ currentFilters: null
11799
+ });
11800
+ }, []);
11801
+ return {
11802
+ ...state,
11803
+ fetchQuestions,
11804
+ loadMore,
11805
+ reset
11806
+ };
11807
+ };
11808
+ var createUseQuestionsList = (apiClient) => {
11809
+ return () => useQuestionsListImpl(apiClient);
11810
+ };
11811
+ var createQuestionsListHook = (apiClient) => {
11812
+ return createUseQuestionsList(apiClient);
11813
+ };
11814
+
11706
11815
  // src/components/Filter/FilterModal.tsx
11707
11816
  import { jsx as jsx57, jsxs as jsxs44 } from "react/jsx-runtime";
11708
11817
  var FilterModal = ({
@@ -11846,10 +11955,10 @@ var FilterModal = ({
11846
11955
  };
11847
11956
 
11848
11957
  // src/components/Filter/useTableFilter.ts
11849
- import { useEffect as useEffect22, useState as useState22, useCallback as useCallback4, useMemo as useMemo10 } from "react";
11958
+ import { useEffect as useEffect22, useState as useState23, useCallback as useCallback5, useMemo as useMemo10 } from "react";
11850
11959
  var useTableFilter = (initialConfigs, options = {}) => {
11851
11960
  const { syncWithUrl = false } = options;
11852
- const getInitialState = useCallback4(() => {
11961
+ const getInitialState = useCallback5(() => {
11853
11962
  if (!syncWithUrl || globalThis.window === void 0) {
11854
11963
  return initialConfigs;
11855
11964
  }
@@ -11867,7 +11976,7 @@ var useTableFilter = (initialConfigs, options = {}) => {
11867
11976
  }));
11868
11977
  return configsWithUrlState;
11869
11978
  }, [initialConfigs, syncWithUrl]);
11870
- const [filterConfigs, setFilterConfigs] = useState22(getInitialState);
11979
+ const [filterConfigs, setFilterConfigs] = useState23(getInitialState);
11871
11980
  const activeFilters = useMemo10(() => {
11872
11981
  const filters = {};
11873
11982
  for (const config of filterConfigs) {
@@ -11880,10 +11989,10 @@ var useTableFilter = (initialConfigs, options = {}) => {
11880
11989
  return filters;
11881
11990
  }, [filterConfigs]);
11882
11991
  const hasActiveFilters = Object.keys(activeFilters).length > 0;
11883
- const updateFilters = useCallback4((configs) => {
11992
+ const updateFilters = useCallback5((configs) => {
11884
11993
  setFilterConfigs(configs);
11885
11994
  }, []);
11886
- const applyFilters = useCallback4(() => {
11995
+ const applyFilters = useCallback5(() => {
11887
11996
  if (!syncWithUrl || globalThis.window === void 0) {
11888
11997
  return;
11889
11998
  }
@@ -11901,7 +12010,7 @@ var useTableFilter = (initialConfigs, options = {}) => {
11901
12010
  }
11902
12011
  globalThis.window.history.replaceState({}, "", url.toString());
11903
12012
  }, [filterConfigs, syncWithUrl]);
11904
- const clearFilters = useCallback4(() => {
12013
+ const clearFilters = useCallback5(() => {
11905
12014
  const clearedConfigs = filterConfigs.map((config) => ({
11906
12015
  ...config,
11907
12016
  categories: config.categories.map((category) => ({
@@ -11942,7 +12051,7 @@ var useTableFilter = (initialConfigs, options = {}) => {
11942
12051
  };
11943
12052
 
11944
12053
  // src/components/ActivityFilters/ActivityFilters.tsx
11945
- import { useState as useState23, useEffect as useEffect23, useMemo as useMemo11, useCallback as useCallback5, useRef as useRef13 } from "react";
12054
+ import { useState as useState24, useEffect as useEffect23, useMemo as useMemo11, useCallback as useCallback6, useRef as useRef13 } from "react";
11946
12055
  import { jsx as jsx58, jsxs as jsxs45 } from "react/jsx-runtime";
11947
12056
  var questionTypesFallback = [
11948
12057
  "ALTERNATIVA" /* ALTERNATIVA */,
@@ -12094,8 +12203,8 @@ var ActivityFilters = ({
12094
12203
  onApplyFilters
12095
12204
  }) => {
12096
12205
  const useActivityFiltersData = createUseActivityFiltersData(apiClient);
12097
- const [selectedQuestionTypes, setSelectedQuestionTypes] = useState23([]);
12098
- const [selectedSubject, setSelectedSubject] = useState23(null);
12206
+ const [selectedQuestionTypes, setSelectedQuestionTypes] = useState24([]);
12207
+ const [selectedSubject, setSelectedSubject] = useState24(null);
12099
12208
  const {
12100
12209
  banks,
12101
12210
  bankYears,
@@ -12151,7 +12260,7 @@ var ActivityFilters = ({
12151
12260
  return prev;
12152
12261
  });
12153
12262
  }, [allowedQuestionTypes]);
12154
- const [bankCategories, setBankCategories] = useState23([]);
12263
+ const [bankCategories, setBankCategories] = useState24([]);
12155
12264
  const selectedSubjects = useMemo11(
12156
12265
  () => selectedSubject ? [selectedSubject] : [],
12157
12266
  [selectedSubject]
@@ -12209,14 +12318,14 @@ var ActivityFilters = ({
12209
12318
  }
12210
12319
  return source.filter((type) => allowedQuestionTypes.includes(type));
12211
12320
  }, [questionTypes, allowedQuestionTypes]);
12212
- const getSelectedKnowledgeIds = useCallback5(() => {
12321
+ const getSelectedKnowledgeIds = useCallback6(() => {
12213
12322
  return getSelectedIdsFromCategories(knowledgeCategories, {
12214
12323
  topicIds: "tema",
12215
12324
  subtopicIds: "subtema",
12216
12325
  contentIds: "assunto"
12217
12326
  });
12218
12327
  }, [knowledgeCategories]);
12219
- const getSelectedBankIds = useCallback5(() => {
12328
+ const getSelectedBankIds = useCallback6(() => {
12220
12329
  return getSelectedIdsFromCategories(bankCategories, {
12221
12330
  bankIds: "banca",
12222
12331
  yearIds: "ano"
@@ -12328,7 +12437,7 @@ var ActivityFiltersPopover = ({
12328
12437
  triggerLabel = "Filtro de quest\xF5es",
12329
12438
  ...activityFiltersProps
12330
12439
  }) => {
12331
- const [open, setOpen] = useState23(false);
12440
+ const [open, setOpen] = useState24(false);
12332
12441
  return /* @__PURE__ */ jsxs45(DropdownMenu_default, { open, onOpenChange: setOpen, children: [
12333
12442
  /* @__PURE__ */ jsx58(DropdownMenuTrigger, { children: /* @__PURE__ */ jsx58(Button_default, { variant: "outline", children: triggerLabel }) }),
12334
12443
  /* @__PURE__ */ jsx58(
@@ -12350,7 +12459,7 @@ var ActivityFiltersPopover = ({
12350
12459
  };
12351
12460
 
12352
12461
  // src/components/TableProvider/TableProvider.tsx
12353
- import { useState as useState24, useEffect as useEffect24, useMemo as useMemo12, useCallback as useCallback6 } from "react";
12462
+ import { useState as useState25, useEffect as useEffect24, useMemo as useMemo12, useCallback as useCallback7 } from "react";
12354
12463
  import { Funnel } from "phosphor-react";
12355
12464
  import { Fragment as Fragment11, jsx as jsx59, jsxs as jsxs46 } from "react/jsx-runtime";
12356
12465
  function TableProvider({
@@ -12374,7 +12483,7 @@ function TableProvider({
12374
12483
  onRowClick,
12375
12484
  children
12376
12485
  }) {
12377
- const [searchQuery, setSearchQuery] = useState24("");
12486
+ const [searchQuery, setSearchQuery] = useState25("");
12378
12487
  const sortResultRaw = useTableSort(data, { syncWithUrl: true });
12379
12488
  const sortResult = enableTableSort ? sortResultRaw : {
12380
12489
  sortedData: data,
@@ -12415,9 +12524,9 @@ function TableProvider({
12415
12524
  totalItems,
12416
12525
  totalPages
12417
12526
  } = paginationConfig;
12418
- const [currentPage, setCurrentPage] = useState24(1);
12419
- const [itemsPerPage, setItemsPerPage] = useState24(defaultItemsPerPage);
12420
- const [isFilterModalOpen, setIsFilterModalOpen] = useState24(false);
12527
+ const [currentPage, setCurrentPage] = useState25(1);
12528
+ const [itemsPerPage, setItemsPerPage] = useState25(defaultItemsPerPage);
12529
+ const [isFilterModalOpen, setIsFilterModalOpen] = useState25(false);
12421
12530
  const combinedParams = useMemo12(() => {
12422
12531
  const params = {
12423
12532
  page: currentPage,
@@ -12448,23 +12557,23 @@ function TableProvider({
12448
12557
  useEffect24(() => {
12449
12558
  onParamsChange?.(combinedParams);
12450
12559
  }, [combinedParams]);
12451
- const handleSearchChange = useCallback6((value) => {
12560
+ const handleSearchChange = useCallback7((value) => {
12452
12561
  setSearchQuery(value);
12453
12562
  setCurrentPage(1);
12454
12563
  }, []);
12455
- const handleFilterApply = useCallback6(() => {
12564
+ const handleFilterApply = useCallback7(() => {
12456
12565
  applyFilters();
12457
12566
  setIsFilterModalOpen(false);
12458
12567
  setCurrentPage(1);
12459
12568
  }, [applyFilters]);
12460
- const handlePageChange = useCallback6((page) => {
12569
+ const handlePageChange = useCallback7((page) => {
12461
12570
  setCurrentPage(page);
12462
12571
  }, []);
12463
- const handleItemsPerPageChange = useCallback6((items) => {
12572
+ const handleItemsPerPageChange = useCallback7((items) => {
12464
12573
  setItemsPerPage(items);
12465
12574
  setCurrentPage(1);
12466
12575
  }, []);
12467
- const handleRowClickInternal = useCallback6(
12576
+ const handleRowClickInternal = useCallback7(
12468
12577
  (row, index) => {
12469
12578
  if (enableRowClick && onRowClick) {
12470
12579
  onRowClick(row, index);
@@ -13007,7 +13116,7 @@ import {
13007
13116
  isValidElement as isValidElement7,
13008
13117
  Children as Children7,
13009
13118
  cloneElement as cloneElement7,
13010
- useState as useState25
13119
+ useState as useState26
13011
13120
  } from "react";
13012
13121
  import { CaretLeft as CaretLeft4, CaretRight as CaretRight7 } from "phosphor-react";
13013
13122
  import { jsx as jsx61, jsxs as jsxs48 } from "react/jsx-runtime";
@@ -13245,8 +13354,8 @@ var MenuOverflow = ({
13245
13354
  ...props
13246
13355
  }) => {
13247
13356
  const containerRef = useRef15(null);
13248
- const [showLeftArrow, setShowLeftArrow] = useState25(false);
13249
- const [showRightArrow, setShowRightArrow] = useState25(false);
13357
+ const [showLeftArrow, setShowLeftArrow] = useState26(false);
13358
+ const [showRightArrow, setShowRightArrow] = useState26(false);
13250
13359
  useEffect26(() => {
13251
13360
  const checkScroll = () => internalCheckScroll(
13252
13361
  containerRef.current,
@@ -13572,9 +13681,9 @@ var NotFound_default = NotFound;
13572
13681
  // src/components/VideoPlayer/VideoPlayer.tsx
13573
13682
  import {
13574
13683
  useRef as useRef16,
13575
- useState as useState27,
13684
+ useState as useState28,
13576
13685
  useEffect as useEffect27,
13577
- useCallback as useCallback8
13686
+ useCallback as useCallback9
13578
13687
  } from "react";
13579
13688
  import { createPortal } from "react-dom";
13580
13689
  import {
@@ -13589,7 +13698,7 @@ import {
13589
13698
  } from "phosphor-react";
13590
13699
 
13591
13700
  // src/components/DownloadButton/DownloadButton.tsx
13592
- import { useCallback as useCallback7, useState as useState26 } from "react";
13701
+ import { useCallback as useCallback8, useState as useState27 } from "react";
13593
13702
  import { DownloadSimple } from "phosphor-react";
13594
13703
  import { jsx as jsx64 } from "react/jsx-runtime";
13595
13704
  var getMimeType = (url) => {
@@ -13666,13 +13775,13 @@ var DownloadButton = ({
13666
13775
  lessonTitle = "aula",
13667
13776
  disabled = false
13668
13777
  }) => {
13669
- const [isDownloading, setIsDownloading] = useState26(false);
13670
- const isValidUrl = useCallback7((url) => {
13778
+ const [isDownloading, setIsDownloading] = useState27(false);
13779
+ const isValidUrl = useCallback8((url) => {
13671
13780
  return Boolean(
13672
13781
  url && url.trim() !== "" && url !== "undefined" && url !== "null"
13673
13782
  );
13674
13783
  }, []);
13675
- const getAvailableContent = useCallback7(() => {
13784
+ const getAvailableContent = useCallback8(() => {
13676
13785
  const downloads = [];
13677
13786
  if (isValidUrl(content.urlDoc)) {
13678
13787
  downloads.push({
@@ -13707,7 +13816,7 @@ var DownloadButton = ({
13707
13816
  }
13708
13817
  return downloads;
13709
13818
  }, [content, isValidUrl]);
13710
- const handleDownload = useCallback7(async () => {
13819
+ const handleDownload = useCallback8(async () => {
13711
13820
  if (disabled || isDownloading) return;
13712
13821
  const availableContent = getAvailableContent();
13713
13822
  if (availableContent.length === 0) {
@@ -13942,26 +14051,26 @@ var VideoPlayer = ({
13942
14051
  }) => {
13943
14052
  const videoRef = useRef16(null);
13944
14053
  const { isUltraSmallMobile, isTinyMobile } = useMobile();
13945
- const [isPlaying, setIsPlaying] = useState27(false);
13946
- const [currentTime, setCurrentTime] = useState27(0);
13947
- const [duration, setDuration] = useState27(0);
13948
- const [isMuted, setIsMuted] = useState27(false);
13949
- const [volume, setVolume] = useState27(1);
13950
- const [isFullscreen, setIsFullscreen] = useState27(false);
13951
- const [showControls, setShowControls] = useState27(true);
13952
- const [hasCompleted, setHasCompleted] = useState27(false);
13953
- const [showCaptions, setShowCaptions] = useState27(false);
13954
- const [subtitlesValidation, setSubtitlesValidation] = useState27("idle");
14054
+ const [isPlaying, setIsPlaying] = useState28(false);
14055
+ const [currentTime, setCurrentTime] = useState28(0);
14056
+ const [duration, setDuration] = useState28(0);
14057
+ const [isMuted, setIsMuted] = useState28(false);
14058
+ const [volume, setVolume] = useState28(1);
14059
+ const [isFullscreen, setIsFullscreen] = useState28(false);
14060
+ const [showControls, setShowControls] = useState28(true);
14061
+ const [hasCompleted, setHasCompleted] = useState28(false);
14062
+ const [showCaptions, setShowCaptions] = useState28(false);
14063
+ const [subtitlesValidation, setSubtitlesValidation] = useState28("idle");
13955
14064
  useEffect27(() => {
13956
14065
  setHasCompleted(false);
13957
14066
  }, [src]);
13958
- const [playbackRate, setPlaybackRate] = useState27(1);
13959
- const [showSpeedMenu, setShowSpeedMenu] = useState27(false);
14067
+ const [playbackRate, setPlaybackRate] = useState28(1);
14068
+ const [showSpeedMenu, setShowSpeedMenu] = useState28(false);
13960
14069
  const lastSaveTimeRef = useRef16(0);
13961
14070
  const trackRef = useRef16(null);
13962
14071
  const controlsTimeoutRef = useRef16(null);
13963
14072
  const lastMousePositionRef = useRef16({ x: 0, y: 0 });
13964
- const isUserInteracting = useCallback8(() => {
14073
+ const isUserInteracting = useCallback9(() => {
13965
14074
  if (showSpeedMenu) {
13966
14075
  return true;
13967
14076
  }
@@ -13978,13 +14087,13 @@ var VideoPlayer = ({
13978
14087
  }
13979
14088
  return false;
13980
14089
  }, [showSpeedMenu]);
13981
- const clearControlsTimeout = useCallback8(() => {
14090
+ const clearControlsTimeout = useCallback9(() => {
13982
14091
  if (controlsTimeoutRef.current) {
13983
14092
  clearTimeout(controlsTimeoutRef.current);
13984
14093
  controlsTimeoutRef.current = null;
13985
14094
  }
13986
14095
  }, []);
13987
- const showControlsWithTimer = useCallback8(() => {
14096
+ const showControlsWithTimer = useCallback9(() => {
13988
14097
  setShowControls(true);
13989
14098
  clearControlsTimeout();
13990
14099
  if (isFullscreen) {
@@ -13999,7 +14108,7 @@ var VideoPlayer = ({
13999
14108
  }, CONTROLS_HIDE_TIMEOUT);
14000
14109
  }
14001
14110
  }, [isFullscreen, isPlaying, clearControlsTimeout]);
14002
- const handleMouseMove = useCallback8(
14111
+ const handleMouseMove = useCallback9(
14003
14112
  (event) => {
14004
14113
  const currentX = event.clientX;
14005
14114
  const currentY = event.clientY;
@@ -14012,10 +14121,10 @@ var VideoPlayer = ({
14012
14121
  },
14013
14122
  [showControlsWithTimer]
14014
14123
  );
14015
- const handleMouseEnter = useCallback8(() => {
14124
+ const handleMouseEnter = useCallback9(() => {
14016
14125
  showControlsWithTimer();
14017
14126
  }, [showControlsWithTimer]);
14018
- const handleMouseLeave = useCallback8(() => {
14127
+ const handleMouseLeave = useCallback9(() => {
14019
14128
  const userInteracting = isUserInteracting();
14020
14129
  clearControlsTimeout();
14021
14130
  if (!isFullscreen && !userInteracting) {
@@ -14120,7 +14229,7 @@ var VideoPlayer = ({
14120
14229
  };
14121
14230
  }
14122
14231
  }, []);
14123
- const getInitialTime = useCallback8(() => {
14232
+ const getInitialTime = useCallback9(() => {
14124
14233
  if (!autoSave || !storageKey) {
14125
14234
  return Number.isFinite(initialTime) && initialTime >= 0 ? initialTime : void 0;
14126
14235
  }
@@ -14140,7 +14249,7 @@ var VideoPlayer = ({
14140
14249
  setCurrentTime(start);
14141
14250
  }
14142
14251
  }, [getInitialTime]);
14143
- const saveProgress = useCallback8(
14252
+ const saveProgress = useCallback9(
14144
14253
  (time) => {
14145
14254
  if (!autoSave || !storageKey) return;
14146
14255
  const now = Date.now();
@@ -14151,7 +14260,7 @@ var VideoPlayer = ({
14151
14260
  },
14152
14261
  [autoSave, storageKey, src]
14153
14262
  );
14154
- const togglePlayPause = useCallback8(async () => {
14263
+ const togglePlayPause = useCallback9(async () => {
14155
14264
  const video = videoRef.current;
14156
14265
  if (!video) return;
14157
14266
  if (!video.paused) {
@@ -14163,7 +14272,7 @@ var VideoPlayer = ({
14163
14272
  } catch {
14164
14273
  }
14165
14274
  }, []);
14166
- const handleVolumeChange = useCallback8(
14275
+ const handleVolumeChange = useCallback9(
14167
14276
  (newVolume) => {
14168
14277
  const video = videoRef.current;
14169
14278
  if (!video) return;
@@ -14182,7 +14291,7 @@ var VideoPlayer = ({
14182
14291
  },
14183
14292
  [isMuted]
14184
14293
  );
14185
- const toggleMute = useCallback8(() => {
14294
+ const toggleMute = useCallback9(() => {
14186
14295
  const video = videoRef.current;
14187
14296
  if (!video) return;
14188
14297
  if (isMuted) {
@@ -14196,20 +14305,20 @@ var VideoPlayer = ({
14196
14305
  setIsMuted(true);
14197
14306
  }
14198
14307
  }, [isMuted, volume]);
14199
- const handleSeek = useCallback8((newTime) => {
14308
+ const handleSeek = useCallback9((newTime) => {
14200
14309
  const video = videoRef.current;
14201
14310
  if (video) {
14202
14311
  video.currentTime = newTime;
14203
14312
  }
14204
14313
  }, []);
14205
- const isSafariIOS = useCallback8(() => {
14314
+ const isSafariIOS = useCallback9(() => {
14206
14315
  const ua = navigator.userAgent;
14207
14316
  const isIOS = /iPad|iPhone|iPod/.test(ua);
14208
14317
  const isWebKit = /WebKit/.test(ua);
14209
14318
  const isNotChrome = !/CriOS|Chrome/.test(ua);
14210
14319
  return isIOS && isWebKit && isNotChrome;
14211
14320
  }, []);
14212
- const toggleFullscreen = useCallback8(() => {
14321
+ const toggleFullscreen = useCallback9(() => {
14213
14322
  const video = videoRef.current;
14214
14323
  const container = video?.parentElement;
14215
14324
  if (!video || !container) return;
@@ -14226,24 +14335,24 @@ var VideoPlayer = ({
14226
14335
  document.exitFullscreen();
14227
14336
  }
14228
14337
  }, [isFullscreen, isSafariIOS]);
14229
- const handleSpeedChange = useCallback8((speed) => {
14338
+ const handleSpeedChange = useCallback9((speed) => {
14230
14339
  if (videoRef.current) {
14231
14340
  videoRef.current.playbackRate = speed;
14232
14341
  setPlaybackRate(speed);
14233
14342
  setShowSpeedMenu(false);
14234
14343
  }
14235
14344
  }, []);
14236
- const toggleSpeedMenu = useCallback8(() => {
14345
+ const toggleSpeedMenu = useCallback9(() => {
14237
14346
  setShowSpeedMenu(!showSpeedMenu);
14238
14347
  }, [showSpeedMenu]);
14239
- const toggleCaptions = useCallback8(() => {
14348
+ const toggleCaptions = useCallback9(() => {
14240
14349
  if (!trackRef.current?.track || !subtitles || subtitlesValidation !== "valid")
14241
14350
  return;
14242
14351
  const newShowCaptions = !showCaptions;
14243
14352
  setShowCaptions(newShowCaptions);
14244
14353
  trackRef.current.track.mode = newShowCaptions ? "showing" : "hidden";
14245
14354
  }, [showCaptions, subtitles, subtitlesValidation]);
14246
- const checkVideoCompletion = useCallback8(
14355
+ const checkVideoCompletion = useCallback9(
14247
14356
  (progressPercent) => {
14248
14357
  if (progressPercent >= 95 && !hasCompleted) {
14249
14358
  setHasCompleted(true);
@@ -14252,7 +14361,7 @@ var VideoPlayer = ({
14252
14361
  },
14253
14362
  [hasCompleted, onVideoComplete]
14254
14363
  );
14255
- const handleTimeUpdate = useCallback8(() => {
14364
+ const handleTimeUpdate = useCallback9(() => {
14256
14365
  const video = videoRef.current;
14257
14366
  if (!video) return;
14258
14367
  const current = video.currentTime;
@@ -14265,7 +14374,7 @@ var VideoPlayer = ({
14265
14374
  checkVideoCompletion(progressPercent);
14266
14375
  }
14267
14376
  }, [duration, saveProgress, onTimeUpdate, onProgress, checkVideoCompletion]);
14268
- const handleLoadedMetadata = useCallback8(() => {
14377
+ const handleLoadedMetadata = useCallback9(() => {
14269
14378
  if (videoRef.current) {
14270
14379
  setDuration(videoRef.current.duration);
14271
14380
  }
@@ -14344,54 +14453,54 @@ var VideoPlayer = ({
14344
14453
  };
14345
14454
  }, [isPlaying, clearControlsTimeout]);
14346
14455
  const progressPercentage = duration > 0 ? currentTime / duration * 100 : 0;
14347
- const getIconSize2 = useCallback8(() => {
14456
+ const getIconSize2 = useCallback9(() => {
14348
14457
  if (isTinyMobile) return 18;
14349
14458
  if (isUltraSmallMobile) return 20;
14350
14459
  return 24;
14351
14460
  }, [isTinyMobile, isUltraSmallMobile]);
14352
- const getControlsPadding = useCallback8(() => {
14461
+ const getControlsPadding = useCallback9(() => {
14353
14462
  if (isTinyMobile) return "px-2 pb-2 pt-1";
14354
14463
  if (isUltraSmallMobile) return "px-3 pb-3 pt-1";
14355
14464
  return "px-4 pb-4";
14356
14465
  }, [isTinyMobile, isUltraSmallMobile]);
14357
- const getControlsGap = useCallback8(() => {
14466
+ const getControlsGap = useCallback9(() => {
14358
14467
  if (isTinyMobile) return "gap-1";
14359
14468
  if (isUltraSmallMobile) return "gap-2";
14360
14469
  return "gap-4";
14361
14470
  }, [isTinyMobile, isUltraSmallMobile]);
14362
- const getProgressBarPadding = useCallback8(() => {
14471
+ const getProgressBarPadding = useCallback9(() => {
14363
14472
  if (isTinyMobile) return "px-2 pb-1";
14364
14473
  if (isUltraSmallMobile) return "px-3 pb-1";
14365
14474
  return "px-4 pb-2";
14366
14475
  }, [isTinyMobile, isUltraSmallMobile]);
14367
- const getCenterPlayButtonPosition = useCallback8(() => {
14476
+ const getCenterPlayButtonPosition = useCallback9(() => {
14368
14477
  if (isTinyMobile) return "items-center justify-center -translate-y-12";
14369
14478
  if (isUltraSmallMobile) return "items-center justify-center -translate-y-8";
14370
14479
  return "items-center justify-center";
14371
14480
  }, [isTinyMobile, isUltraSmallMobile]);
14372
- const getTopControlsOpacity = useCallback8(() => {
14481
+ const getTopControlsOpacity = useCallback9(() => {
14373
14482
  return showControls ? "opacity-100" : "opacity-0";
14374
14483
  }, [showControls]);
14375
- const getBottomControlsOpacity = useCallback8(() => {
14484
+ const getBottomControlsOpacity = useCallback9(() => {
14376
14485
  return showControls ? "opacity-100" : "opacity-0";
14377
14486
  }, [showControls]);
14378
- const seekBackward = useCallback8(() => {
14487
+ const seekBackward = useCallback9(() => {
14379
14488
  if (videoRef.current) {
14380
14489
  videoRef.current.currentTime -= 10;
14381
14490
  }
14382
14491
  }, []);
14383
- const seekForward = useCallback8(() => {
14492
+ const seekForward = useCallback9(() => {
14384
14493
  if (videoRef.current) {
14385
14494
  videoRef.current.currentTime += 10;
14386
14495
  }
14387
14496
  }, []);
14388
- const increaseVolume = useCallback8(() => {
14497
+ const increaseVolume = useCallback9(() => {
14389
14498
  handleVolumeChange(Math.min(100, volume * 100 + 10));
14390
14499
  }, [handleVolumeChange, volume]);
14391
- const decreaseVolume = useCallback8(() => {
14500
+ const decreaseVolume = useCallback9(() => {
14392
14501
  handleVolumeChange(Math.max(0, volume * 100 - 10));
14393
14502
  }, [handleVolumeChange, volume]);
14394
- const handleVideoKeyDown = useCallback8(
14503
+ const handleVideoKeyDown = useCallback9(
14395
14504
  (e) => {
14396
14505
  if (!e.key) return;
14397
14506
  e.stopPropagation();
@@ -14634,7 +14743,7 @@ var VideoPlayer = ({
14634
14743
  var VideoPlayer_default = VideoPlayer;
14635
14744
 
14636
14745
  // src/components/Whiteboard/Whiteboard.tsx
14637
- import { useCallback as useCallback9, useState as useState28 } from "react";
14746
+ import { useCallback as useCallback10, useState as useState29 } from "react";
14638
14747
  import { ArrowsOut } from "phosphor-react";
14639
14748
  import { Fragment as Fragment13, jsx as jsx66, jsxs as jsxs52 } from "react/jsx-runtime";
14640
14749
  var IMAGE_WIDTH = 225;
@@ -14647,8 +14756,8 @@ var Whiteboard = ({
14647
14756
  imagesPerRow = 2,
14648
14757
  ...rest
14649
14758
  }) => {
14650
- const [imageErrors, setImageErrors] = useState28(/* @__PURE__ */ new Set());
14651
- const handleDownload = useCallback9(
14759
+ const [imageErrors, setImageErrors] = useState29(/* @__PURE__ */ new Set());
14760
+ const handleDownload = useCallback10(
14652
14761
  (image) => {
14653
14762
  if (onDownload) {
14654
14763
  onDownload(image);
@@ -14665,7 +14774,7 @@ var Whiteboard = ({
14665
14774
  },
14666
14775
  [onDownload]
14667
14776
  );
14668
- const handleImageError = useCallback9((imageId) => {
14777
+ const handleImageError = useCallback10((imageId) => {
14669
14778
  setImageErrors((prev) => new Set(prev).add(imageId));
14670
14779
  }, []);
14671
14780
  const gridColsClass = images?.length === 1 ? "grid-cols-1" : {
@@ -14756,8 +14865,8 @@ import {
14756
14865
  createContext,
14757
14866
  useContext,
14758
14867
  useEffect as useEffect28,
14759
- useState as useState29,
14760
- useCallback as useCallback10,
14868
+ useState as useState30,
14869
+ useCallback as useCallback11,
14761
14870
  useMemo as useMemo13
14762
14871
  } from "react";
14763
14872
  import { useLocation, Navigate } from "react-router-dom";
@@ -14772,12 +14881,12 @@ var AuthProvider = ({
14772
14881
  getSessionFn,
14773
14882
  getTokensFn
14774
14883
  }) => {
14775
- const [authState, setAuthState] = useState29({
14884
+ const [authState, setAuthState] = useState30({
14776
14885
  isAuthenticated: false,
14777
14886
  isLoading: true,
14778
14887
  ...initialAuthState
14779
14888
  });
14780
- const checkAuth = useCallback10(async () => {
14889
+ const checkAuth = useCallback11(async () => {
14781
14890
  try {
14782
14891
  setAuthState((prev) => ({ ...prev, isLoading: true }));
14783
14892
  if (!checkAuthFn) {
@@ -14808,7 +14917,7 @@ var AuthProvider = ({
14808
14917
  return false;
14809
14918
  }
14810
14919
  }, [checkAuthFn, getUserFn, getSessionFn, getTokensFn]);
14811
- const signOut = useCallback10(() => {
14920
+ const signOut = useCallback11(() => {
14812
14921
  if (signOutFn) {
14813
14922
  signOutFn();
14814
14923
  }
@@ -15115,22 +15224,22 @@ import {
15115
15224
  import {
15116
15225
  forwardRef as forwardRef22,
15117
15226
  useEffect as useEffect32,
15118
- useState as useState32
15227
+ useState as useState33
15119
15228
  } from "react";
15120
15229
 
15121
15230
  // src/components/Quiz/QuizContent.tsx
15122
15231
  import {
15123
15232
  forwardRef as forwardRef21,
15124
- useCallback as useCallback11,
15233
+ useCallback as useCallback12,
15125
15234
  useEffect as useEffect31,
15126
15235
  useId as useId11,
15127
15236
  useMemo as useMemo15,
15128
15237
  useRef as useRef18,
15129
- useState as useState31
15238
+ useState as useState32
15130
15239
  } from "react";
15131
15240
 
15132
15241
  // src/components/MultipleChoice/MultipleChoice.tsx
15133
- import { useEffect as useEffect30, useState as useState30 } from "react";
15242
+ import { useEffect as useEffect30, useState as useState31 } from "react";
15134
15243
  import { CheckCircle as CheckCircle5, XCircle as XCircle4, Check as Check5 } from "phosphor-react";
15135
15244
  import { jsx as jsx68, jsxs as jsxs53 } from "react/jsx-runtime";
15136
15245
  var MultipleChoiceList = ({
@@ -15142,7 +15251,7 @@ var MultipleChoiceList = ({
15142
15251
  onHandleSelectedValues,
15143
15252
  mode = "interactive"
15144
15253
  }) => {
15145
- const [actualValue, setActualValue] = useState30(selectedValues);
15254
+ const [actualValue, setActualValue] = useState31(selectedValues);
15146
15255
  useEffect30(() => {
15147
15256
  setActualValue(selectedValues);
15148
15257
  }, [selectedValues]);
@@ -15414,7 +15523,7 @@ var QuizMultipleChoice = ({ paddingBottom }) => {
15414
15523
  variant,
15415
15524
  currentQuestionResult?.selectedOptions
15416
15525
  ]);
15417
- const handleSelectedValues = useCallback11(
15526
+ const handleSelectedValues = useCallback12(
15418
15527
  (values) => {
15419
15528
  if (currentQuestion) {
15420
15529
  selectMultipleAnswer(currentQuestion.id, values);
@@ -15490,7 +15599,7 @@ var QuizDissertative = ({ paddingBottom }) => {
15490
15599
  selectDissertativeAnswer(currentQuestion.id, value);
15491
15600
  }
15492
15601
  };
15493
- const adjustTextareaHeight = useCallback11(() => {
15602
+ const adjustTextareaHeight = useCallback12(() => {
15494
15603
  if (textareaRef.current) {
15495
15604
  textareaRef.current.style.height = "auto";
15496
15605
  const scrollHeight = textareaRef.current.scrollHeight;
@@ -15641,7 +15750,7 @@ var QuizConnectDots = ({ paddingBottom }) => {
15641
15750
  isCorrect: false
15642
15751
  }
15643
15752
  ];
15644
- const [userAnswers, setUserAnswers] = useState31(() => {
15753
+ const [userAnswers, setUserAnswers] = useState32(() => {
15645
15754
  if (variant === "result") {
15646
15755
  return mockUserAnswers;
15647
15756
  }
@@ -15760,7 +15869,7 @@ var QuizFill = ({ paddingBottom }) => {
15760
15869
  isCorrect: true
15761
15870
  }
15762
15871
  ];
15763
- const [answers, setAnswers] = useState31({});
15872
+ const [answers, setAnswers] = useState32({});
15764
15873
  const baseId = useId11();
15765
15874
  const getAvailableOptionsForSelect = (selectId) => {
15766
15875
  const usedOptions = new Set(
@@ -15900,7 +16009,7 @@ var QuizImageQuestion = ({ paddingBottom }) => {
15900
16009
  };
15901
16010
  const correctRadiusRelative = calculateCorrectRadiusRelative();
15902
16011
  const mockUserAnswerRelative = { x: 0.72, y: 0.348 };
15903
- const [clickPositionRelative, setClickPositionRelative] = useState31(variant == "result" ? mockUserAnswerRelative : null);
16012
+ const [clickPositionRelative, setClickPositionRelative] = useState32(variant == "result" ? mockUserAnswerRelative : null);
15904
16013
  const convertToRelativeCoordinates = (x, y, rect) => {
15905
16014
  const safeWidth = Math.max(rect.width, 1e-3);
15906
16015
  const safeHeight = Math.max(rect.height, 1e-3);
@@ -16083,7 +16192,7 @@ var QuizTitle = forwardRef22(({ className, onBack, ...props }, ref) => {
16083
16192
  formatTime: formatTime2,
16084
16193
  isStarted
16085
16194
  } = useQuizStore();
16086
- const [showExitConfirmation, setShowExitConfirmation] = useState32(false);
16195
+ const [showExitConfirmation, setShowExitConfirmation] = useState33(false);
16087
16196
  const totalQuestions = getTotalQuestions();
16088
16197
  const quizTitle = getQuizTitle();
16089
16198
  const handleBackClick = () => {
@@ -16286,8 +16395,8 @@ var QuizFooter = forwardRef22(
16286
16395
  const currentAnswer = getCurrentAnswer();
16287
16396
  const currentQuestion = getCurrentQuestion();
16288
16397
  const isCurrentQuestionSkipped = currentQuestion ? getQuestionStatusFromUserAnswers(currentQuestion.id) === "skipped" : false;
16289
- const [activeModal, setActiveModal] = useState32(null);
16290
- const [filterType, setFilterType] = useState32("all");
16398
+ const [activeModal, setActiveModal] = useState33(null);
16399
+ const [filterType, setFilterType] = useState33("all");
16291
16400
  const openModal = (modalName) => setActiveModal(modalName);
16292
16401
  const closeModal = () => setActiveModal(null);
16293
16402
  const isModalOpen = (modalName) => activeModal === modalName;
@@ -16629,7 +16738,7 @@ var QuizFooter = forwardRef22(
16629
16738
  );
16630
16739
 
16631
16740
  // src/components/Quiz/QuizResult.tsx
16632
- import { forwardRef as forwardRef23, useEffect as useEffect33, useState as useState33 } from "react";
16741
+ import { forwardRef as forwardRef23, useEffect as useEffect33, useState as useState34 } from "react";
16633
16742
  import { Clock as Clock3 } from "phosphor-react";
16634
16743
  import { jsx as jsx71, jsxs as jsxs56 } from "react/jsx-runtime";
16635
16744
  var QuizBadge = ({
@@ -16658,7 +16767,7 @@ var QuizHeaderResult = forwardRef23(
16658
16767
  getCurrentQuestion,
16659
16768
  questionsResult
16660
16769
  } = useQuizStore();
16661
- const [status, setStatus] = useState33(void 0);
16770
+ const [status, setStatus] = useState34(void 0);
16662
16771
  useEffect33(() => {
16663
16772
  const cq = getCurrentQuestion();
16664
16773
  if (!cq) {
@@ -17211,9 +17320,9 @@ var useUrlParams = (config) => {
17211
17320
  import { useMemo as useMemo17 } from "react";
17212
17321
 
17213
17322
  // src/hooks/useInstitution.ts
17214
- import { useEffect as useEffect35, useState as useState34 } from "react";
17323
+ import { useEffect as useEffect35, useState as useState35 } from "react";
17215
17324
  function useInstitutionId() {
17216
- const [institutionId, setInstitutionId] = useState34(() => {
17325
+ const [institutionId, setInstitutionId] = useState35(() => {
17217
17326
  return document.querySelector('meta[name="institution-id"]')?.getAttribute("content") ?? null;
17218
17327
  });
17219
17328
  useEffect35(() => {
@@ -17420,7 +17529,7 @@ function useAppInitialization() {
17420
17529
  }
17421
17530
 
17422
17531
  // src/hooks/useAppContent.ts
17423
- import { useCallback as useCallback12, useEffect as useEffect36, useMemo as useMemo18 } from "react";
17532
+ import { useCallback as useCallback13, useEffect as useEffect36, useMemo as useMemo18 } from "react";
17424
17533
  import { useNavigate as useNavigate2 } from "react-router-dom";
17425
17534
  function useAppContent(config) {
17426
17535
  const navigate = useNavigate2();
@@ -17446,20 +17555,20 @@ function useAppContent(config) {
17446
17555
  navigate("/painel");
17447
17556
  }
17448
17557
  };
17449
- const handleSetSelectedProfile = useCallback12(
17558
+ const handleSetSelectedProfile = useCallback13(
17450
17559
  (profile) => {
17451
17560
  setSelectedProfile(profile);
17452
17561
  },
17453
17562
  [setSelectedProfile]
17454
17563
  );
17455
- const handleClearParamsFromURL = useCallback12(() => {
17564
+ const handleClearParamsFromURL = useCallback13(() => {
17456
17565
  if (onClearParamsFromURL) {
17457
17566
  onClearParamsFromURL();
17458
17567
  } else {
17459
17568
  globalThis.location.replace("/painel");
17460
17569
  }
17461
17570
  }, [onClearParamsFromURL]);
17462
- const handleError = useCallback12(
17571
+ const handleError = useCallback13(
17463
17572
  (error) => {
17464
17573
  if (onError) {
17465
17574
  onError(error);
@@ -17763,7 +17872,7 @@ var formatDateToBrazilian = (dateString) => {
17763
17872
  };
17764
17873
 
17765
17874
  // src/components/ActivityDetails/ActivityDetails.tsx
17766
- import { useState as useState35, useMemo as useMemo20, useCallback as useCallback13, useEffect as useEffect37 } from "react";
17875
+ import { useState as useState36, useMemo as useMemo20, useCallback as useCallback14, useEffect as useEffect37 } from "react";
17767
17876
  import { Medal as Medal2, Star as Star2, File as File2, CaretRight as CaretRight9, WarningCircle as WarningCircle7 } from "phosphor-react";
17768
17877
  import { Fragment as Fragment17, jsx as jsx74, jsxs as jsxs58 } from "react/jsx-runtime";
17769
17878
  var createTableColumns = (onCorrectActivity) => [
@@ -17861,19 +17970,19 @@ var ActivityDetails = ({
17861
17970
  mapSubjectNameToEnum
17862
17971
  }) => {
17863
17972
  const { isMobile } = useMobile();
17864
- const [page, setPage] = useState35(1);
17865
- const [limit, setLimit] = useState35(10);
17866
- const [sortBy, setSortBy] = useState35(void 0);
17867
- const [sortOrder, setSortOrder] = useState35(
17973
+ const [page, setPage] = useState36(1);
17974
+ const [limit, setLimit] = useState36(10);
17975
+ const [sortBy, setSortBy] = useState36(void 0);
17976
+ const [sortOrder, setSortOrder] = useState36(
17868
17977
  void 0
17869
17978
  );
17870
- const [data, setData] = useState35(null);
17871
- const [correctionData, setCorrectionData] = useState35(null);
17872
- const [loading, setLoading] = useState35(true);
17873
- const [error, setError] = useState35(null);
17874
- const [isModalOpen, setIsModalOpen] = useState35(false);
17875
- const [isViewOnlyModal, setIsViewOnlyModal] = useState35(false);
17876
- const [correctionError, setCorrectionError] = useState35(null);
17979
+ const [data, setData] = useState36(null);
17980
+ const [correctionData, setCorrectionData] = useState36(null);
17981
+ const [loading, setLoading] = useState36(true);
17982
+ const [error, setError] = useState36(null);
17983
+ const [isModalOpen, setIsModalOpen] = useState36(false);
17984
+ const [isViewOnlyModal, setIsViewOnlyModal] = useState36(false);
17985
+ const [correctionError, setCorrectionError] = useState36(null);
17877
17986
  useEffect37(() => {
17878
17987
  const loadData = async () => {
17879
17988
  if (!activityId) return;
@@ -17897,7 +18006,7 @@ var ActivityDetails = ({
17897
18006
  };
17898
18007
  loadData();
17899
18008
  }, [activityId, page, limit, sortBy, sortOrder, fetchActivityDetails]);
17900
- const handleCorrectActivity = useCallback13(
18009
+ const handleCorrectActivity = useCallback14(
17901
18010
  async (studentId) => {
17902
18011
  const student = data?.students.find((s) => s.studentId === studentId);
17903
18012
  if (!student || !activityId) return;
@@ -17917,10 +18026,10 @@ var ActivityDetails = ({
17917
18026
  },
17918
18027
  [data?.students, activityId, fetchStudentCorrection]
17919
18028
  );
17920
- const handleCloseModal = useCallback13(() => {
18029
+ const handleCloseModal = useCallback14(() => {
17921
18030
  setIsModalOpen(false);
17922
18031
  }, []);
17923
- const handleObservationSubmit = useCallback13(
18032
+ const handleObservationSubmit = useCallback14(
17924
18033
  async (observation, files) => {
17925
18034
  if (!activityId || !correctionData?.studentId) return;
17926
18035
  try {
@@ -18206,7 +18315,7 @@ var ActivityDetails = ({
18206
18315
  };
18207
18316
 
18208
18317
  // src/components/Support/Support.tsx
18209
- import { useState as useState37, useEffect as useEffect39 } from "react";
18318
+ import { useState as useState38, useEffect as useEffect39 } from "react";
18210
18319
  import { useForm } from "react-hook-form";
18211
18320
  import { zodResolver } from "@hookform/resolvers/zod";
18212
18321
  import {
@@ -18237,7 +18346,7 @@ var supportSchema = z.object({
18237
18346
  });
18238
18347
 
18239
18348
  // src/components/Support/components/TicketModal.tsx
18240
- import { useState as useState36, useEffect as useEffect38, useCallback as useCallback14 } from "react";
18349
+ import { useState as useState37, useEffect as useEffect38, useCallback as useCallback15 } from "react";
18241
18350
  import dayjs from "dayjs";
18242
18351
  import "dayjs/locale/pt-br";
18243
18352
 
@@ -18359,17 +18468,17 @@ var TicketModal = ({
18359
18468
  apiClient,
18360
18469
  userId
18361
18470
  }) => {
18362
- const [showCloseConfirmation, setShowCloseConfirmation] = useState36(false);
18363
- const [responseText, setResponseText] = useState36("");
18364
- const [answers, setAnswers] = useState36([]);
18365
- const [isSubmittingAnswer, setIsSubmittingAnswer] = useState36(false);
18366
- const [isLoadingAnswers, setIsLoadingAnswers] = useState36(false);
18471
+ const [showCloseConfirmation, setShowCloseConfirmation] = useState37(false);
18472
+ const [responseText, setResponseText] = useState37("");
18473
+ const [answers, setAnswers] = useState37([]);
18474
+ const [isSubmittingAnswer, setIsSubmittingAnswer] = useState37(false);
18475
+ const [isLoadingAnswers, setIsLoadingAnswers] = useState37(false);
18367
18476
  const handleCloseTicket = () => {
18368
18477
  onTicketClose?.(ticket.id);
18369
18478
  setShowCloseConfirmation(false);
18370
18479
  onClose();
18371
18480
  };
18372
- const fetchAnswers = useCallback14(async () => {
18481
+ const fetchAnswers = useCallback15(async () => {
18373
18482
  if (!ticket.id || ticket.status !== "respondido" /* RESPONDIDO */) return;
18374
18483
  setIsLoadingAnswers(true);
18375
18484
  try {
@@ -18791,21 +18900,21 @@ var Support = ({
18791
18900
  onTicketCreated,
18792
18901
  onTicketClosed
18793
18902
  }) => {
18794
- const [activeTab, setActiveTab] = useState37("criar-pedido");
18795
- const [selectedProblem, setSelectedProblem] = useState37(null);
18796
- const [statusFilter, setStatusFilter] = useState37("todos");
18797
- const [categoryFilter, setCategoryFilter] = useState37("todos");
18798
- const [selectedTicket, setSelectedTicket] = useState37(
18903
+ const [activeTab, setActiveTab] = useState38("criar-pedido");
18904
+ const [selectedProblem, setSelectedProblem] = useState38(null);
18905
+ const [statusFilter, setStatusFilter] = useState38("todos");
18906
+ const [categoryFilter, setCategoryFilter] = useState38("todos");
18907
+ const [selectedTicket, setSelectedTicket] = useState38(
18799
18908
  null
18800
18909
  );
18801
- const [isModalOpen, setIsModalOpen] = useState37(false);
18802
- const [submitError, setSubmitError] = useState37(null);
18803
- const [showSuccessToast, setShowSuccessToast] = useState37(false);
18804
- const [showCloseSuccessToast, setShowCloseSuccessToast] = useState37(false);
18805
- const [showCloseErrorToast, setShowCloseErrorToast] = useState37(false);
18806
- const [allTickets, setAllTickets] = useState37([]);
18807
- const [loadingTickets, setLoadingTickets] = useState37(false);
18808
- const [currentPage, setCurrentPage] = useState37(1);
18910
+ const [isModalOpen, setIsModalOpen] = useState38(false);
18911
+ const [submitError, setSubmitError] = useState38(null);
18912
+ const [showSuccessToast, setShowSuccessToast] = useState38(false);
18913
+ const [showCloseSuccessToast, setShowCloseSuccessToast] = useState38(false);
18914
+ const [showCloseErrorToast, setShowCloseErrorToast] = useState38(false);
18915
+ const [allTickets, setAllTickets] = useState38([]);
18916
+ const [loadingTickets, setLoadingTickets] = useState38(false);
18917
+ const [currentPage, setCurrentPage] = useState38(1);
18809
18918
  const ITEMS_PER_PAGE = 10;
18810
18919
  const handlePrevPage = () => {
18811
18920
  if (currentPage > 1) {
@@ -19337,9 +19446,11 @@ export {
19337
19446
  createActivityFiltersDataHook,
19338
19447
  createNotificationStore,
19339
19448
  createNotificationsHook,
19449
+ createQuestionsListHook,
19340
19450
  createUseActivityFiltersData,
19341
19451
  createUseNotificationStore,
19342
19452
  createUseNotifications,
19453
+ createUseQuestionsList,
19343
19454
  createZustandAuthAdapter,
19344
19455
  formatDateToBrazilian,
19345
19456
  formatFileSize,