@dereekb/trello 13.11.14 → 13.11.15

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.
@@ -55,7 +55,7 @@ export type TrelloPageItemIdReader<T> = (item: T) => TrelloId;
55
55
  /**
56
56
  * Default reader that pulls `id` off the item. Works for most Trello resource types.
57
57
  *
58
- * @param item The page item whose id to read.
58
+ * @param item - The page item whose id to read.
59
59
  * @returns The item's id.
60
60
  */
61
61
  export declare const defaultTrelloPageItemIdReader: <T extends {
@@ -64,7 +64,7 @@ export declare const defaultTrelloPageItemIdReader: <T extends {
64
64
  /**
65
65
  * Reader that pulls the action id off a Trello action item.
66
66
  *
67
- * @param item The action page item whose id to read.
67
+ * @param item - The action page item whose id to read.
68
68
  * @returns The item's action id.
69
69
  */
70
70
  export declare const trelloActionIdReader: <T extends {
@@ -73,10 +73,11 @@ export declare const trelloActionIdReader: <T extends {
73
73
  /**
74
74
  * Wraps a raw Trello collection fetch into a {@link TrelloPageResult}.
75
75
  *
76
- * @param input The page filter that was used.
77
- * @param data The raw page items.
78
- * @param idReader Function to read the id from the last item.
76
+ * @param input - The page filter that was used.
77
+ * @param data - The raw page items.
78
+ * @param idReader - Function to read the id from the last item.
79
79
  * @returns A page result with the data and a cursor for the next page.
80
+ *
80
81
  * @__NO_SIDE_EFFECTS__
81
82
  */
82
83
  export declare function buildTrelloPageResult<T>(input: TrelloCursorPageFilter, data: ReadonlyArray<T>, idReader: TrelloPageItemIdReader<T>): TrelloPageResult<T>;
@@ -84,9 +85,10 @@ export type TrelloFetchPageFetchFunction<I extends TrelloCursorPageFilter, R ext
84
85
  /**
85
86
  * Creates a FetchPageFactory using the input TrelloFetchPageFetchFunction.
86
87
  *
87
- * @param fetch Function that fetches a single page of results from the Trello API.
88
- * @param defaults Optional default pagination configuration.
88
+ * @param fetch - Function that fetches a single page of results from the Trello API.
89
+ * @param defaults - Optional default pagination configuration.
89
90
  * @returns A configured FetchPageFactory that handles Trello's cursor-based pagination using `before`.
91
+ *
90
92
  * @__NO_SIDE_EFFECTS__
91
93
  */
92
94
  export declare function trelloFetchPageFactory<I extends TrelloCursorPageFilter, R extends TrelloPageResult<unknown>>(fetch: TrelloFetchPageFetchFunction<I, R>, defaults?: Maybe<FetchPageFactoryConfigDefaults>): FetchPageFactory<I, R>;
@@ -1,4 +1,4 @@
1
- import { type TrelloApiKey, type TrelloApiToken, type TrelloApiUrl } from './trello.type';
1
+ import { type TrelloApiKey, type TrelloApiToken } from './trello.type';
2
2
  /**
3
3
  * Configuration for a TrelloContext.
4
4
  */
@@ -16,5 +16,5 @@ export interface TrelloConfig {
16
16
  /**
17
17
  * Optional custom API base URL. Defaults to https://api.trello.com/1.
18
18
  */
19
- readonly apiUrl?: TrelloApiUrl | string;
19
+ readonly apiUrl?: string;
20
20
  }
@@ -53,8 +53,9 @@ export type LogTrelloServerErrorFunction = (error: FetchRequestFactoryError | Tr
53
53
  /**
54
54
  * Creates a logTrelloServerErrorFunction that logs the error to console.
55
55
  *
56
- * @param trelloApiNamePrefix Prefix to use when logging.
57
- * @returns A function that logs Trello server errors to the console.
56
+ * @param trelloApiNamePrefix - Prefix to use when logging.
57
+ * @returns Logs Trello server errors to the console.
58
+ *
58
59
  * @__NO_SIDE_EFFECTS__
59
60
  */
60
61
  export declare function logTrelloServerErrorFunction(trelloApiNamePrefix: string): LogTrelloServerErrorFunction;
@@ -62,16 +63,17 @@ export declare const logTrelloErrorToConsole: LogTrelloServerErrorFunction;
62
63
  /**
63
64
  * Parses a FetchResponseError into a typed Trello API error.
64
65
  *
65
- * @param responseError The fetch response error to parse.
66
+ * @param responseError - The fetch response error to parse.
66
67
  * @returns A typed Trello error, or undefined if the response could not be parsed.
67
68
  */
68
69
  export declare function parseTrelloApiError(responseError: FetchResponseError): Promise<Maybe<TrelloServerFetchResponseError>>;
69
70
  /**
70
71
  * Wraps a ConfiguredFetch to translate FetchResponseError into typed Trello errors.
71
72
  *
72
- * @param fetch The fetch to wrap.
73
- * @param logError Optional logger.
73
+ * @param fetch - The fetch to wrap.
74
+ * @param logError - Optional logger.
74
75
  * @returns A ConfiguredFetch that throws typed Trello errors for known error responses.
76
+ *
75
77
  * @__NO_SIDE_EFFECTS__
76
78
  */
77
79
  export declare function handleTrelloErrorFetch(fetch: ConfiguredFetch, logError?: LogTrelloServerErrorFunction): ConfiguredFetch;
@@ -33,8 +33,9 @@ export type TrelloRateLimitedFetchHandler = RateLimitedFetchHandler<ResetPeriodP
33
33
  *
34
34
  * Backs off after 429 responses and respects the documented per-token rate limit.
35
35
  *
36
- * @param config Optional configuration for rate limiting behavior.
36
+ * @param config - Optional configuration for rate limiting behavior.
37
37
  * @returns A configured rate-limited fetch handler.
38
+ *
38
39
  * @__NO_SIDE_EFFECTS__
39
40
  */
40
41
  export declare function trelloRateLimitedFetchHandler(config?: Maybe<TrelloRateLimitedFetchHandlerConfig>): TrelloRateLimitedFetchHandler;