Skip to content

Commit be7dabd

Browse files
zimegClaude
andcommitted
revert(block-kit): drop # type: ignore on carousel card icon/hero_image
Examples should not carry type-checker suppressions. Remove the # type: ignore[arg-type] added for the ImageElement icon/hero_image args. Until slackapi/python-slack-sdk#1937 lands (widening CardBlock.icon / hero_image to accept an image element), mypy reports [arg-type] here by design — the honest signal that slack_sdk mis-types these fields as str. Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>
1 parent e361a30 commit be7dabd

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

block-kit/src/blocks/carousel.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,13 @@ def example01() -> CarouselBlock:
1515
elements=[
1616
CardBlock(
1717
block_id="carousel-card-1",
18-
icon=ImageElement( # type: ignore[arg-type]
18+
icon=ImageElement(
1919
image_url="https://picsum.photos/36/36",
2020
alt_text="Icon",
2121
),
2222
title=MarkdownTextObject(text="MDR"),
2323
subtitle=MarkdownTextObject(text="Refining data files"),
24-
hero_image=ImageElement( # type: ignore[arg-type]
24+
hero_image=ImageElement(
2525
image_url="https://picsum.photos/400/300",
2626
alt_text="Sample hero image",
2727
),
@@ -35,15 +35,15 @@ def example01() -> CarouselBlock:
3535
),
3636
CardBlock(
3737
block_id="carousel-card-2",
38-
icon=ImageElement( # type: ignore[arg-type]
38+
icon=ImageElement(
3939
image_url="https://picsum.photos/36/36",
4040
alt_text="Icon",
4141
),
4242
title=MarkdownTextObject(text="O&D"),
4343
subtitle=MarkdownTextObject(
4444
text="Storage, maintenance, and rotation of art pieces"
4545
),
46-
hero_image=ImageElement( # type: ignore[arg-type]
46+
hero_image=ImageElement(
4747
image_url="https://picsum.photos/400/300",
4848
alt_text="Sample hero image",
4949
),
@@ -57,13 +57,13 @@ def example01() -> CarouselBlock:
5757
),
5858
CardBlock(
5959
block_id="carousel-card-3",
60-
icon=ImageElement( # type: ignore[arg-type]
60+
icon=ImageElement(
6161
image_url="https://picsum.photos/36/36",
6262
alt_text="Icon",
6363
),
6464
title=MarkdownTextObject(text="Wellness Center"),
6565
subtitle=MarkdownTextObject(text="Wellness sessions"),
66-
hero_image=ImageElement( # type: ignore[arg-type]
66+
hero_image=ImageElement(
6767
image_url="https://picsum.photos/400/300",
6868
alt_text="Sample hero image",
6969
),

0 commit comments

Comments
 (0)