<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Angular component in Map Popup Content in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1538175#M85667</link>
    <description>&lt;P&gt;Sorry for the late response. I have been very busy with my projects.&lt;BR /&gt;&lt;BR /&gt;Anyway, I tried your example and adapt it to my code.&lt;/P&gt;&lt;P&gt;This is how I create from your example&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;TestPopupComponent (HTML &amp;amp; Typescript)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;p&amp;gt;This is the message from input --- {{message}}&amp;lt;/p&amp;gt;&lt;/LI-CODE&gt;&lt;LI-CODE lang="javascript"&gt;import { Component, Input } from '@angular/core';

@Component({
  selector: 'mea-test-popup-component',
  templateUrl: './test-popup-component.component.html',
  styleUrls: ['./test-popup-component.component.scss']
})
export class TestPopupComponentComponent {
  @Input() message: string = ''
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;MainComponent&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt; import { Injector, Renderer2, RendererFactory2, inject } from '@angular/core';
import { NgElement, WithProperties, createCustomElement } from '@angular/elements';
import CustomContent from '@arcgis/core/popup/content/CustomContent';
import { TestPopupComponent } from './test-popup-component/test-popup.component';   

//From mapView on click
displayPopup(mapPoint: Point){
        if (!customElements.get('mea-test-popup-component')) {
            const popupElement = createCustomElement(TestPopupComponent, { injector: this._injector });
            customElements.define('mea-test-popup-component', popupElement);
        }
        const testComponent: NgElement &amp;amp; WithProperties&amp;lt;TestPopupComponent&amp;gt; = this._renderer2.createElement('mea-test-popup-component');
        testComponent.message = 'Hello, world!';
        this.mapView.openPopup({
            content: testComponent,
            location: mapPoint,
        });
    }&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;The Result&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="WoraminSat_0-1726221673838.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/114988iCD4A405CFBE9D0A6/image-size/medium?v=v2&amp;amp;px=400" role="button" title="WoraminSat_0-1726221673838.png" alt="WoraminSat_0-1726221673838.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;------------&lt;BR /&gt;&lt;BR /&gt;Thank you very much for your help!&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 13 Sep 2024 10:08:04 GMT</pubDate>
    <dc:creator>WoraminSat</dc:creator>
    <dc:date>2024-09-13T10:08:04Z</dc:date>
    <item>
      <title>Angular component in Map Popup Content</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1527659#M85501</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Is there any way to insert Angular component into Map Popup Content?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example ,&lt;/P&gt;&lt;P&gt;const dataPopup = { name : "John Doe" , departmentId : 1 };&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;const mapPopup = new Popup();&lt;/P&gt;&lt;P&gt;popup.content = "&amp;lt;my-custom-content [propsA]="dataPopup " /&amp;gt;";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;------------------&lt;/P&gt;&lt;P&gt;In React I use to create custom component with Virtual DOM, but I have no idea how to do with Angular Component.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If anyone has an idea to achieve this, please share it with me.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Woramin S.&lt;/P&gt;</description>
      <pubDate>Tue, 27 Aug 2024 07:14:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1527659#M85501</guid>
      <dc:creator>WoraminSat</dc:creator>
      <dc:date>2024-08-27T07:14:41Z</dc:date>
    </item>
    <item>
      <title>Re: Angular component in Map Popup Content</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1527796#M85505</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Convert Angular component to Custom element&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://angular.dev/guide/elements" target="_blank"&gt;https://angular.dev/guide/elements&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Aug 2024 11:43:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1527796#M85505</guid>
      <dc:creator>ForrestLin</dc:creator>
      <dc:date>2024-08-27T11:43:05Z</dc:date>
    </item>
    <item>
      <title>Re: Angular component in Map Popup Content</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1527861#M85506</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is how I &lt;SPAN&gt;create CustomContent (and&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;PopupTemplate)&lt;/SPAN&gt;&amp;nbsp;using Angular component:&amp;nbsp;&lt;SPAN&gt;PopupComponent.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;import&lt;/SPAN&gt;&lt;SPAN&gt; { &lt;/SPAN&gt;&lt;SPAN&gt;Injector&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;Renderer2&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;RendererFactory2&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;inject&lt;/SPAN&gt;&lt;SPAN&gt; } &lt;/SPAN&gt;&lt;SPAN&gt;from&lt;/SPAN&gt; &lt;SPAN&gt;"@angular/core"&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;import&lt;/SPAN&gt;&lt;SPAN&gt; { &lt;/SPAN&gt;&lt;SPAN&gt;NgElement&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;WithProperties&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;createCustomElement&lt;/SPAN&gt;&lt;SPAN&gt; } &lt;/SPAN&gt;&lt;SPAN&gt;from&lt;/SPAN&gt; &lt;SPAN&gt;"@angular/elements"&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;import&lt;/SPAN&gt; &lt;SPAN&gt;CustomContent&lt;/SPAN&gt; &lt;SPAN&gt;from&lt;/SPAN&gt; &lt;SPAN&gt;"@arcgis/core/popup/content/CustomContent"&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;_renderer2&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;Renderer2&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;inject&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;RendererFactory2&lt;/SPAN&gt;&lt;SPAN&gt;).&lt;/SPAN&gt;&lt;SPAN&gt;createRenderer&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;null&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;null&lt;/SPAN&gt;&lt;SPAN&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;_injector&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;inject&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;Injector&lt;/SPAN&gt;&lt;SPAN&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;createP&lt;/SPAN&gt;&lt;SPAN&gt;opupTemplate&lt;/SPAN&gt;&lt;SPAN&gt;(): &lt;/SPAN&gt;&lt;SPAN&gt;PopupTemplate&lt;/SPAN&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;const&lt;/SPAN&gt; &lt;SPAN&gt;popupTemplate&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;new&lt;/SPAN&gt; &lt;SPAN&gt;PopupTemplate&lt;/SPAN&gt;&lt;SPAN&gt;({&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;title&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;this&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;title&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;outFields&lt;/SPAN&gt;&lt;SPAN&gt;: [&lt;/SPAN&gt;&lt;SPAN&gt;"*"&lt;/SPAN&gt;&lt;SPAN&gt;],&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;content&lt;/SPAN&gt;&lt;SPAN&gt;: [&lt;/SPAN&gt;&lt;SPAN&gt;this&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;FONT color="#FF0000"&gt;createCustomContent&lt;/FONT&gt;()&lt;/SPAN&gt;&lt;SPAN&gt;],&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;actions&lt;/SPAN&gt;&lt;SPAN&gt;: [],&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;fieldInfos&lt;/SPAN&gt;&lt;SPAN&gt;: []&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; });&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;return&lt;/SPAN&gt; &lt;SPAN&gt;popupTemplate&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; }&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &lt;FONT color="#FF0000"&gt;createC&lt;/FONT&gt;&lt;/SPAN&gt;&lt;FONT color="#FF0000"&gt;&lt;SPAN&gt;ustomContent&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN&gt;(): &lt;/SPAN&gt;&lt;SPAN&gt;CustomContent&lt;/SPAN&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;const&lt;/SPAN&gt; &lt;SPAN&gt;customContent&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;new&lt;/SPAN&gt; &lt;FONT color="#FF0000"&gt;&lt;SPAN&gt;CustomContent&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN&gt;({&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;outFields&lt;/SPAN&gt;&lt;SPAN&gt;: [&lt;/SPAN&gt;&lt;SPAN&gt;"*"&lt;/SPAN&gt;&lt;SPAN&gt;],&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;creator&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;event&lt;/SPAN&gt; &lt;SPAN&gt;=&amp;gt;&lt;/SPAN&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;this&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;_graphic&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;event&lt;/SPAN&gt;&lt;SPAN&gt;?.&lt;/SPAN&gt;&lt;SPAN&gt;graphic&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;const&lt;/SPAN&gt; &lt;SPAN&gt;popupEl&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;this&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;FONT color="#FF0000"&gt;&lt;SPAN&gt;createPopupElement&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN&gt;&lt;FONT color="#FF0000"&gt;()&lt;/FONT&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;return&lt;/SPAN&gt; &lt;FONT color="#FF0000"&gt;&lt;SPAN&gt;popupEl&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; });&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;return&lt;/SPAN&gt; &lt;FONT color="#FF0000"&gt;&lt;SPAN&gt;customContent&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; }&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;FONT color="#FF0000"&gt;&lt;SPAN&gt;createPopupElement&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN&gt;(): &lt;/SPAN&gt;&lt;SPAN&gt;NgElement&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;WithProperties&lt;/SPAN&gt;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN&gt;PopupComponent&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt; {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;if&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;SPAN&gt;!&lt;/SPAN&gt;&lt;SPAN&gt;customElements&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;get&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'popup'&lt;/SPAN&gt;&lt;SPAN&gt;)) {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;const&lt;/SPAN&gt; &lt;SPAN&gt;popupElement&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;createCustomElement&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;PopupComponent&lt;/SPAN&gt;&lt;SPAN&gt;, { &lt;/SPAN&gt;&lt;SPAN&gt;injector&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;SPAN&gt;this&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;_injector&lt;/SPAN&gt;&lt;SPAN&gt; });&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;customElements&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;define&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'popup'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;popupElement&lt;/SPAN&gt;&lt;SPAN&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; }&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;const&lt;/SPAN&gt; &lt;SPAN&gt;popupElement&lt;/SPAN&gt;&lt;SPAN&gt;: &lt;/SPAN&gt;&lt;FONT color="#FF0000"&gt;&lt;SPAN&gt;NgElement&lt;/SPAN&gt;&lt;SPAN&gt; &amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;WithProperties&lt;/SPAN&gt;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN&gt;PopupComponent&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt; &lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN&gt;=&lt;/SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;this&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;_renderer2&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;createElement&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'popup'&lt;/SPAN&gt;&lt;SPAN&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;return&lt;/SPAN&gt; &lt;FONT color="#FF0000"&gt;&lt;SPAN&gt;popupElement&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN&gt;!&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; }&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ForrestLin_0-1724767409897.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/113614i8A190B6ED261AE48/image-size/medium?v=v2&amp;amp;px=400" role="button" title="ForrestLin_0-1724767409897.png" alt="ForrestLin_0-1724767409897.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Aug 2024 15:36:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1527861#M85506</guid>
      <dc:creator>ForrestLin</dc:creator>
      <dc:date>2024-08-27T15:36:39Z</dc:date>
    </item>
    <item>
      <title>Re: Angular component in Map Popup Content</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1538175#M85667</link>
      <description>&lt;P&gt;Sorry for the late response. I have been very busy with my projects.&lt;BR /&gt;&lt;BR /&gt;Anyway, I tried your example and adapt it to my code.&lt;/P&gt;&lt;P&gt;This is how I create from your example&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;TestPopupComponent (HTML &amp;amp; Typescript)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;p&amp;gt;This is the message from input --- {{message}}&amp;lt;/p&amp;gt;&lt;/LI-CODE&gt;&lt;LI-CODE lang="javascript"&gt;import { Component, Input } from '@angular/core';

@Component({
  selector: 'mea-test-popup-component',
  templateUrl: './test-popup-component.component.html',
  styleUrls: ['./test-popup-component.component.scss']
})
export class TestPopupComponentComponent {
  @Input() message: string = ''
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;MainComponent&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt; import { Injector, Renderer2, RendererFactory2, inject } from '@angular/core';
import { NgElement, WithProperties, createCustomElement } from '@angular/elements';
import CustomContent from '@arcgis/core/popup/content/CustomContent';
import { TestPopupComponent } from './test-popup-component/test-popup.component';   

//From mapView on click
displayPopup(mapPoint: Point){
        if (!customElements.get('mea-test-popup-component')) {
            const popupElement = createCustomElement(TestPopupComponent, { injector: this._injector });
            customElements.define('mea-test-popup-component', popupElement);
        }
        const testComponent: NgElement &amp;amp; WithProperties&amp;lt;TestPopupComponent&amp;gt; = this._renderer2.createElement('mea-test-popup-component');
        testComponent.message = 'Hello, world!';
        this.mapView.openPopup({
            content: testComponent,
            location: mapPoint,
        });
    }&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;The Result&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="WoraminSat_0-1726221673838.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/114988iCD4A405CFBE9D0A6/image-size/medium?v=v2&amp;amp;px=400" role="button" title="WoraminSat_0-1726221673838.png" alt="WoraminSat_0-1726221673838.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;------------&lt;BR /&gt;&lt;BR /&gt;Thank you very much for your help!&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Sep 2024 10:08:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1538175#M85667</guid>
      <dc:creator>WoraminSat</dc:creator>
      <dc:date>2024-09-13T10:08:04Z</dc:date>
    </item>
    <item>
      <title>Re: Angular component in Map Popup Content</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1538204#M85668</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/826107"&gt;@WoraminSat&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Great!&lt;/P&gt;</description>
      <pubDate>Fri, 13 Sep 2024 12:06:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/angular-component-in-map-popup-content/m-p/1538204#M85668</guid>
      <dc:creator>ForrestLin</dc:creator>
      <dc:date>2024-09-13T12:06:29Z</dc:date>
    </item>
  </channel>
</rss>

