Skip to content

Conversation

@madebyisaacr
Copy link
Collaborator

@madebyisaacr madebyisaacr commented Jun 18, 2025

Description

This pull request adds support for more field types to the Airtable plugin.

  • Add support for these Airtable field types:
    • Lookup
    • Rollup
    • Barcode
    • AI Text
    • Collaborator
    • Multiple Collaborators
    • Created By
    • Last Edited By
    • Count
  • Allow importing URL as Plain Text field.
  • Fixed warning spam for empty number fields.
  • Fixed importing duration field. Previously it would only import as a number of seconds, now it imports as a string by default and uses the same hour minute second formatting as shown in the Airtable app.

Notes:

  • User/collaborator fields are imported as the user's name, same as the Notion plugin.
  • Array fields (lookup and multiple collaborators) only import the first value. When we have support for gallery fields and later arrays for all field types, we can update this to import as an array instead of only the first value.

Currently marked as draft. Will open for review after I have thoroughly tested all changes.

Testing

None yet.

@madebyisaacr madebyisaacr changed the title Airtable plugin improvements Airtable: add Barcode, AI Text, and Duration fields + import Colors Jun 19, 2025
@madebyisaacr madebyisaacr changed the title Airtable: add Barcode, AI Text, and Duration fields + import Colors Airtable: add Barcode, AI Text, and Duration fields Jun 19, 2025
@madebyisaacr madebyisaacr changed the title Airtable: add Barcode, AI Text, and Duration fields Airtable: add Lookup, Rollup, Barcode, AI Text, and Duration fields Jun 20, 2025
@madebyisaacr madebyisaacr changed the title Airtable: add Lookup, Rollup, Barcode, AI Text, and Duration fields Airtable: add Lookup, Rollup, Barcode, AI Text, User, and Duration fields Jun 20, 2025
@madebyisaacr madebyisaacr marked this pull request as ready for review June 25, 2025 19:13
@triozer triozer requested a review from Copilot June 30, 2025 13:10
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for additional Airtable field types including Lookup, Rollup, Barcode, AI Text, Collaborator, and Duration fields, while also refining data import logic and addressing warning spam.

  • Introduced new field inference functions for Barcode, AI Text, Duration, and Collaborator fields.
  • Updated number field handling by replacing "duration" with "count" and adjusted API types to remove the deprecated "lookup" type.
  • Enhanced field mapping logic and styling adjustments in FieldMapping.tsx and App.css.

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
plugins/airtable/src/fields.ts Added new inference functions and properties for additional field types; refactored type handling.
plugins/airtable/src/data.ts Updated field data processing to support new field types and proper value extraction.
plugins/airtable/src/api.ts Modified API types to remove outdated lookup types and align with new field schema.
plugins/airtable/src/FieldMapping.tsx Adjusted UI logic for field type selection and mapping improvements.
plugins/airtable/src/App.css Added styling for the new field-type select component.
Comments suppressed due to low confidence (2)

plugins/airtable/src/fields.ts:1

  • There are no tests currently covering the new field inference logic for Barcode, AI Text, Duration, and Collaborator fields. Please add tests to verify their behavior and ensure reliable functionality.
import type { ManagedCollection, ManagedCollectionFieldInput } from "framer-plugin"

plugins/airtable/src/api.ts:312

  • The API type union has been updated by removing the deprecated 'lookup' field type in favor of 'multipleLookupValues'. Please update the documentation accordingly to reflect this breaking change.
        | { type: "createdTime"; options: AirtableFieldOptions["createdTime"] }

* The original Airtable field schema options.
* Only set when fields are inferred.
*/
readonly airtableOptions?: AirtableFieldSchema["options"]
Copy link

Copilot AI Jun 30, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] Multiple inference functions repeat assignments for 'airtableOptions' and 'originalAirtableType'. Consider refactoring this repeated logic into a common helper function to reduce duplication.

Copilot uses AI. Check for mistakes.
@triozer triozer requested a review from tom-james-watson June 30, 2025 13:18
@madebyisaacr
Copy link
Collaborator Author

Closing because I screwed up when rebasing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant